Page MenuHomeSoftware Heritage

readme and cli description update
ClosedPublic

Authored by DanSeraf on Thu, Sep 3, 4:01 PM.

Diff Detail

Repository
rDTSCN Code scanner
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

DanSeraf created this revision.Thu, Sep 3, 4:01 PM

Build is green

Patch application report for D3876 (id=13671)

Rebasing onto d4f9b2d6d6...

Current branch diff-target is up to date.
Changes applied before test
commit 1353b53baebb2bb4c4f8fd991d8eb8a6031a9473
Author: Daniele Serafini <me@danieleserafini.eu>
Date:   Thu Sep 3 16:01:15 2020 +0200

    readme and cli description update

See https://jenkins.softwareheritage.org/job/DTSCN/job/tests-on-diff/37/ for more details.

zack requested changes to this revision.Thu, Sep 3, 4:39 PM
zack added a subscriber: zack.
zack added inline comments.
docs/README.rst
0

This is fine, but maintaining here a duplication of the auto-generated --help message is not a great idea (it violates the DRY principle and all that). Instead of this, I suggest doing what we did for the swh-model CLI documentation, which is generated using Sphinx/Click integration.

swh/scanner/cli.py
73–74

Just the other day I was trying to use this, and couldn't.

This help string needs a description of pattern semantics and/or an example of a concrete pattern to help users.
Also, I think there is not default exclusion pattern, but if there is it should be mentioned here.

(And I also think it would be a good idea to exclude stuff like ".git" by default, but that is material for a separate diff.)

This revision now requires changes to proceed.Thu, Sep 3, 4:39 PM
DanSeraf added inline comments.Thu, Sep 3, 5:22 PM
swh/scanner/cli.py
73–74

I think we should also mention that the patterns are translated into regex objects by fnmatch that uses shell-style wildcards.

DanSeraf updated this revision to Diff 13741.Wed, Sep 9, 5:42 PM

requested changes

Build is green

Patch application report for D3876 (id=13741)

Rebasing onto d4f9b2d6d6...

Current branch diff-target is up to date.
Changes applied before test
commit d4e6c2601cb7cf336112027e09a3a4ef0798a35a
Author: Daniele Serafini <me@danieleserafini.eu>
Date:   Wed Sep 9 17:39:47 2020 +0200

    docs: readme and cli description update

See https://jenkins.softwareheritage.org/job/DTSCN/job/tests-on-diff/38/ for more details.

zack requested changes to this revision.Thu, Sep 10, 4:34 PM
zack added inline comments.
README.md
5–6

I've changed this in swh-docs index as follows:

"source code scanner to analyze code bases and compare them with source code artifacts archived by Software Heritage"

can you use the same text here?

setup.py
45

as you are switching from .rst to .md (which is fine!), you should also change this to:

long_description_content_type="text/markdown",

This revision now requires changes to proceed.Thu, Sep 10, 4:34 PM
DanSeraf added inline comments.Thu, Sep 10, 4:41 PM
setup.py
45

oh, i missed that, thanks!

Build is green

Patch application report for D3876 (id=13786)

Rebasing onto d4f9b2d6d6...

Current branch diff-target is up to date.
Changes applied before test
commit ed5cd7f64472e69a8c95216d87712b8ea6078e5a
Author: Daniele Serafini <me@danieleserafini.eu>
Date:   Wed Sep 9 17:39:47 2020 +0200

    docs: readme and cli description update

See https://jenkins.softwareheritage.org/job/DTSCN/job/tests-on-diff/41/ for more details.

zack accepted this revision.Thu, Sep 10, 5:17 PM
This revision is now accepted and ready to land.Thu, Sep 10, 5:17 PM
This revision was landed with ongoing or failed builds.Thu, Sep 10, 5:23 PM
This revision was automatically updated to reflect the committed changes.

Build is green

Patch application report for D3876 (id=13804)

Rebasing onto 9ce6ddc054...

Current branch diff-target is up to date.
Changes applied before test
commit 2fb9cb1c59e2afde3c03ee473fb8f230192082c3
Author: Daniele Serafini <me@danieleserafini.eu>
Date:   Thu Sep 10 17:20:54 2020 +0200

    docs: readme and cli description update

See https://jenkins.softwareheritage.org/job/DTSCN/job/tests-on-diff/43/ for more details.