Add linter: Enforce the source code file naming convention described in the developer notes #13450

pull practicalswift wants to merge 1 commits into bitcoin:master from practicalswift:lint-filenames changing 1 files +21 −0
  1. practicalswift commented at 8:03 pm on June 12, 2018: contributor
    Add linter: Enforce the source code file naming convention described in the developer notes.
  2. in test/lint/lint-filenames.sh:11 in 8cc92e00e4 outdated
     6+#
     7+# Make sure only lowercase alphanumerics (a-z0-9), underscores (_) and
     8+# hyphens (-) are used in source code filenames.
     9+
    10+EXIT_CODE=0
    11+OUTPUT=$(git ls-files -- "*.cpp" "*.h" | grep -vE '^[a-z0-9_./-]+$' | grep -vE 'src/(secp256k1|univalue)/')
    


    MarcoFalke commented at 8:28 pm on June 12, 2018:

    Just noting that this regex doesn’t work for me: [a-z] also covers [A-Z]

    0$ echo 'A'|grep -E '[a-z]'
    1A
    

    practicalswift commented at 9:54 pm on June 12, 2018:

    Oh, good catch – that is probably yet another case of locale dependence!

    • What are your locale settings (LANG, LC_ALL, etc.)? Output from set | grep -E '^(LANG|LC_)' would be helpful.
    • What version of bash are you using?
    • What is the output of shopt | grep globasciiranges?
    • What OS version are you using?

    echo 'A' | LC_ALL=C grep -E '[a-z]' works as expected, right?

    Now updated with LC_ALL=C.


    MarcoFalke commented at 10:33 pm on June 12, 2018:

    echo 'A' | LC_ALL=C grep -E '[a-z]' works now.

    0$ set | grep -E '^(LANG|LC_)' && bash --version | head -1 && shopt | grep globasciiranges && lsb_release -d
    1LANG=en_US.UTF-8
    2GNU bash, version 4.4.19(1)-release (x86_64-redhat-linux-gnu)
    3globasciiranges	off
    4Description:	Fedora release 28 (Twenty Eight)
    
  3. practicalswift force-pushed on Jun 12, 2018
  4. fanquake added the label Scripts and tools on Jun 13, 2018
  5. practicalswift force-pushed on Jun 13, 2018
  6. practicalswift force-pushed on Jun 13, 2018
  7. Add linter: Enforce the source code file naming convention described in the developer notes ad691f666b
  8. practicalswift force-pushed on Jun 14, 2018
  9. ken2812221 approved
  10. ken2812221 commented at 1:35 am on June 15, 2018: contributor
    utACK ad691f6
  11. MarcoFalke commented at 1:35 pm on June 15, 2018: member
    utACK ad691f6
  12. MarcoFalke merged this on Jun 15, 2018
  13. MarcoFalke closed this on Jun 15, 2018

  14. MarcoFalke referenced this in commit 32bf4c619d on Jun 15, 2018
  15. laanwj referenced this in commit 45c00f8416 on Jun 18, 2018
  16. PastaPastaPasta referenced this in commit fa3eed7af9 on Jul 7, 2020
  17. PastaPastaPasta referenced this in commit 65a6976d31 on Jul 29, 2020
  18. PastaPastaPasta referenced this in commit 86c9819fc4 on Jul 29, 2020
  19. PastaPastaPasta referenced this in commit cb5d0d8b99 on Jul 29, 2020
  20. practicalswift deleted the branch on Apr 10, 2021
  21. gades referenced this in commit 34f2d9dfb7 on Mar 8, 2022
  22. DrahtBot locked this on Aug 18, 2022

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2025-11-20 21:13 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me