97 Commits

Author SHA1 Message Date
Xavier Delaruelle
e5f7f99689 script: fix bitwise AND logic on gitlog2changelog.py
Several if conditions where using bitwise AND whereas the intent was to
do a regular AND test.
2023-06-03 08:46:06 +02:00
Xavier Delaruelle
a1b82e75c2 Use Hunspell spell checker instead of Aspell
Following upcoming recommendation of Fedora to depreciate Aspell and
migrate to Hunspell [1]. Update documentation and scripts to use
Hunspell.

[1] https://fedoraproject.org/wiki/Changes/AspellDeprecation
2023-06-01 22:05:52 +02:00
Xavier Delaruelle
2d8360dbab script: apply flake8 suggestions on gitlog2changelog.py
Apply on gitlog2changelog.py most code change suggestions from Flake8
Python style guide enforcement tool.
2023-05-19 21:36:11 +02:00
Xavier Delaruelle
ff98426199 script: apply black suggestions on gitlog2changelog.py
Apply on gitlog2changelog.py code change suggestions from Black Python
code formatter.
2023-05-19 21:36:11 +02:00
Xavier Delaruelle
36f46feeec script: sync gitlog2changelog.py with upstream
Update gitlog2changelog.py script with recent changes made on it in its
upstream repository (https://github.com/networkupstools/nut/).

Keep our local adaptations:
* --pretty=medium git log option
* TextWrapper specific configuration

Remove one local adaptation (newline separator between commits) to obtain
more terse output.
2023-05-19 21:36:11 +02:00
Xavier Delaruelle
fc1ef21548 lint: fix SC2006 shellcheck warning 2023-05-19 21:36:11 +02:00
Xavier Delaruelle
8db45670d7 lint: fix SC2016 shellcheck warning 2023-05-19 21:36:11 +02:00
Xavier Delaruelle
38d400f409 lint: fix SC2076 shellcheck warning 2023-05-19 21:36:11 +02:00
Xavier Delaruelle
47822de203 lint: fix SC2206 shellcheck warning 2023-05-19 21:36:11 +02:00
Xavier Delaruelle
3bf57cc7d7 lint: fix SC2209 shellcheck warning 2023-05-19 21:36:11 +02:00
Xavier Delaruelle
00d57b3d82 lint: fix SC2181 shellcheck warning 2023-05-19 21:36:11 +02:00
Xavier Delaruelle
3a85fb43fd lint: fix SC2268 shellcheck warning 2023-05-19 21:36:11 +02:00
Xavier Delaruelle
a185599f4e lint: fix SC2164 shellcheck warning 2023-05-18 18:43:09 +02:00
Xavier Delaruelle
2506e7e42c script: test some builds with quick testsuite on mrel
Use quick testsuite on git clone and git export builds to speed-up a bit
new release test.
2023-05-15 20:45:16 +02:00
Xavier Delaruelle
2835f6bbb3 install: fix expected log format in gitlog2changelog.py
Update gitlog2changelog.py script to ensure git log format is not
influenced by user git configuration.

Fixes #487.
2023-03-21 06:03:35 +01:00
Xavier Delaruelle
1cd8a67b52 ts: optionally build cache files to run tests
When TESTSUITE_ENABLE_MODULECACHE environment variable is set, cache
file is built for all modulepaths of the testsuite. Tests are run using
the cache files to resolve available modules.
2022-12-27 18:43:59 +01:00
Xavier Delaruelle
3cffd66915 script: skip v5.2 from bench/profile in mb
Ignore Modules v5.2 when benching or profiling releases not to get too
much results on output.
2022-12-24 17:24:52 +01:00
Xavier Delaruelle
50171b10fa script: add benchmark tests for cache in mb
Add cache version of avail, whatis and load benchmark tests in mb tool.
2022-12-24 17:24:52 +01:00
Xavier Delaruelle
3b1faeb181 Use main as new name for default git branch 2022-10-30 13:26:31 +01:00
Lukáš Zaoral
0877b01865 lint(ShellCheck): fix SC2046 warning
According to ShellCheck's documentation:

When command expansions are unquoted, word splitting and globbing will occur.
This often manifests itself by breaking when filenames contain spaces.

Related: https://www.shellcheck.net/wiki/SC2046
Related: #470
2022-09-02 09:52:05 +02:00
Lukáš Zaoral
d018f7a9e6 lint(ShellCheck): fix SC2086 info diagnostic
Some variables, that were unquoted intentionally were converted to arrays.

According to ShellCheck's documentation:

Quoting variables prevents word splitting and glob expansion, and prevents
the script from breaking when input contains spaces, line feeds, glob
characters and such.

Related: https://www.shellcheck.net/wiki/SC2086
Related: #470
2022-09-02 09:52:05 +02:00
Lukáš Zaoral
06b0a89655 lint(ShellCheck): fix SC2048 warning
According to ShellCheck's documentation:

Use "$@" (with quotes) to prevent whitespace problems.  $* and ${array[*]},
unquoted, is subject to word splitting and globbing.

Related: https://www.shellcheck.net/wiki/SC2048
Related: #470
2022-09-02 09:52:05 +02:00
Lukáš Zaoral
65309830cb lint(ShellCheck): fix SC2166 warning
According to ShellCheck's documentation:

-a and -o  in [ .. ] test expressions are not well defined, and can cause
incorrect results when arguments start with dashes or contain !.

Related: https://www.shellcheck.net/wiki/SC2166
Related: #470
2022-09-02 09:52:05 +02:00
Lukáš Zaoral
0ecc9fa480 lint(ShellCheck): fix SC2068 error
According to ShellCheck's documentation:

Double quotes around $@ and ${array[@]}) prevent globbing and word splitting
of individual elements, while still expanding to multiple separate arguments.

Related: https://www.shellcheck.net/wiki/SC2068
Related: #470
2022-09-02 09:52:05 +02:00
Xavier Delaruelle
4dbb6edec4 script: add usage msg and --help option on mtreview 2022-09-01 06:43:38 +02:00
Xavier Delaruelle
3e6b3b9b88 script: add usage msg and --help option on mlprof 2022-09-01 06:43:38 +02:00
Xavier Delaruelle
fbf9f657cf script: add usage msg and --help option on mt 2022-09-01 06:43:38 +02:00
Xavier Delaruelle
e7b1985dde script: keep old releases among benched versions in mb
Update mb script to skip several releases and be able to run bench or
profiling on old and recent releases. Versions 4.1, 4.3, 4.5, 4.7 and
5.1 are retained for bench mode. 4.5, 4.7 and 5.1 are retained for
profile mode.
2022-09-01 06:43:38 +02:00
Xavier Delaruelle
3e31e18cfc script: add usage msg and --help option on mb 2022-09-01 06:43:38 +02:00
Xavier Delaruelle
2105897e95 script: add usage msg and --help option on mrel 2022-09-01 06:43:38 +02:00
Xavier Delaruelle
dc41667c97 script: add usage msg and --help option on mpub 2022-09-01 06:43:38 +02:00
Xavier Delaruelle
6dc8e629da script: fix too long line issues in mb/mrel/nglfar2ccov 2022-09-01 06:43:38 +02:00
Xavier Delaruelle
f5b8e2e08b script: fix lint issues on mrel/mlprof/mtreview 2022-09-01 06:43:38 +02:00
Xavier Delaruelle
7a41543601 ts: add lint testsuite 2022-09-01 06:43:38 +02:00
Xavier Delaruelle
9a119ec5e2 contrib,script: enclose installation path references
Update add.modules script and example modulefiles to enclose all
references to the installation paths.
2022-06-16 18:57:30 +02:00
Xavier Delaruelle
eb8708e470 install: locate rpmlint rc file with -r in mrel
Update mrel script to locate rpmlint rc file with the -r command-line
switch as -f is not recognized anymore on rpmlint v2.
2022-05-31 07:00:20 +02:00
Xavier Delaruelle
60c3a3311b install: add rpmlint rc config file
Add rpmlint rc configuration file to filter false positive warning
messages when checking RPM spec file and built packages.

Update 'mrel' script to use this rc configuration file when linting RPM
spec file.
2022-05-03 14:12:20 +02:00
Xavier Delaruelle
2bb8365cb2 script: no line number dependency for expected errors
Update mpub and mrel scripts not to depend on the line number expressed
in error message when comparing them to expected error message.
2022-05-01 07:38:31 +02:00
Xavier Delaruelle
024fc61bfa script: add commit-msg hook script to check commit msg 2022-03-05 10:54:49 +01:00
Xavier Delaruelle
db43f9815b script: update pre-commit to spell check docs with Aspell 2022-03-05 09:37:41 +01:00
Xavier Delaruelle
f45d8b6375 script: pre-commit warn if codespell not installed 2022-03-05 09:37:41 +01:00
Xavier Delaruelle
ff6a1362b7 script: add pre-commit script to verify commits 2022-03-02 07:31:30 +01:00
Dimitri Papadopoulos
e9a6678eec Fix typos found by codespell 2022-02-15 05:54:03 +01:00
Xavier Delaruelle
cff324bbf0 script: update modshare var name in mb 2021-08-08 13:27:53 +02:00
Xavier Delaruelle
e0e3b6d3b3 script: exclude alpha/beta and old releases in mb
Exclude from bench or profiling tests releases older than 4.3 (or 4.6 in
profiling mode). Also exclude from these tests the alpha and beta
releases.
2021-08-01 09:30:16 +02:00
Xavier Delaruelle
82eda166be script: call nglfar2ccov over each tcl split scripts 2021-08-01 09:30:16 +02:00
Xavier Delaruelle
2d56b7f41e Split main procs and code in dedicated file 2021-07-30 10:11:54 +02:00
Xavier Delaruelle
c77ef6673d script: limit output header length in mb 2021-07-29 17:33:19 +02:00
Xavier Delaruelle
d4da878338 script: consider alpha/beta valid release name in mrel/mpub 2021-07-25 21:36:37 +02:00
Xavier Delaruelle
4dfb4fe6e9 Add '__' prefix to name of loaded env tracking env variable
Rename the environment variables that are used by Modules to track
loaded environment state (variables whose name starts with `MODULES_LM`).
A `__` prefix is added to the name of these variables to indicate that
they are intended for internal use only.
2021-07-24 14:06:09 +02:00