Skip to content

Merge new commits from upstream #1

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1,126 commits into
base: dev/osh-release-0.6.pre15
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
1126 commits
Select commit Hold shift + click to select a range
41c6fb8
test: set our prefix to created temp_cwd dirnames
scop May 22, 2021
170d6db
test(portinstall): test in temporary work dir
scop May 22, 2021
ff4f747
test: remove stale SRCDIRABS TODO comment
scop May 22, 2021
db2e9ef
test(javaws): xfail options test on unparseable -help
scop May 21, 2021
e552575
test(printenv): avoid xfail condition false positive
scop May 22, 2021
328287d
test(prepare_fixture_dir): create dirs before files
scop May 22, 2021
54659ce
test(portinstall): remove unneeded cleanup
scop May 22, 2021
e2e2252
test(man): place on demand created files outside src tree
scop May 22, 2021
72900ba
test: remove no longer needed tmp dir
scop May 22, 2021
4c2f391
test(kdvi,kpdf,evince): use @pytest.mark.bashcomp(temp_cwd=True)
akinomyoga May 22, 2021
4528807
test(diff_env): detect unwanted changes of OLDPWD in test
akinomyoga May 22, 2021
b88ec19
test(conftest): add utilities "bash_{save,restore}_variable(bash,var)"
akinomyoga May 24, 2021
eece182
test(diff_env): use r"\w" in a regular expression
akinomyoga May 26, 2021
8b33f56
test(conftest): add new context manager "bash_env_saved"
akinomyoga May 26, 2021
a975f2f
test(ant): do not duplicate project name in import fixture
scop May 27, 2021
e8fe9ba
test(ant): extract complete-ant-cmd.pl presence to a fixture
scop May 27, 2021
7e0803f
test(ant): do not fail on complete-ant-cmd.pl import prefixes
scop May 27, 2021
d0a7804
style(editorconfig): set commit message max line length to 72
scop May 31, 2021
4a8ab31
completions: invoke "cd" as "command cd"
akinomyoga May 23, 2021
24ca112
completions: add "--" option to "command cd"
akinomyoga May 31, 2021
a7aa054
test({remove,slack}pkg): add "--" option to "command cd"
akinomyoga Jun 1, 2021
6d0c0f5
test(man): fix inactive "required_cmd"
akinomyoga May 29, 2021
ebe9ad6
test(bash_env_saved): correctly restore "cwd"
akinomyoga May 30, 2021
f469727
test(bash_env_saved): continue restoring on restoring error
akinomyoga May 30, 2021
cd39105
test(bash_env_saved): work around nested bash_env
akinomyoga May 30, 2021
a6bb6f4
fix(BASH_COMPLETION_USER_FILE): explicitly check if it is not /dev/null
akinomyoga May 31, 2021
7e65989
test(conftest): prepare temporary file for HISTFILE
akinomyoga Jun 1, 2021
d1c13da
Merge pull request #529 from akinomyoga/fix-test_man
scop Jun 6, 2021
231b528
docs(CONTRIBUTING): note use of Conventional Commits
scop Jun 6, 2021
bd9193a
test(tar,known_hosts,p{gids,pids,names}): use "bash_env_saved"
akinomyoga May 28, 2021
22f6136
test(commitlint): add config, run with pre-commit
scop Jun 6, 2021
74d1f56
docs(CONTRIBUTING): note --hook-type's in pre-commit set up
scop Jun 6, 2021
538307b
test(pre-commit): confine code checks to pre-commit stage
scop Jun 6, 2021
fec79fb
Merge pull request #540 from akinomyoga/use-bash_env_saved
scop Jun 6, 2021
6377641
refactor(slackpkg): deprecate in favor of upstream one in >= 15.0.4
scop Jun 4, 2021
186b0df
Merge pull request #535 from scop/refactor/deprecate-slackpkg
scop Jun 6, 2021
50cc808
test(conftest): prevent MAGIC_MARK from history expansions
akinomyoga Jun 6, 2021
5e9c9a0
Merge pull request #543 from akinomyoga/fix-MAGIC_MARK
scop Jun 14, 2021
d07e980
feat(ssh-keyscan): new completion
scop Jun 3, 2021
01959d2
test(conftest): support @pytest.mark.bashcomp(required_cmd=True)
akinomyoga Jun 20, 2021
33df79c
Merge pull request #547 from akinomyoga/support-bashcmop-require_cmd
akinomyoga Jun 30, 2021
1893481
feat(ssh-keyscan): complete comma separated -t args
scop Jul 4, 2021
1364e71
Merge pull request #541 from scop/docs/commit-messages
scop Jul 5, 2021
5dd8b27
test(pre-commit): upgrade black to 21.6b0
scop Jul 5, 2021
57c2099
test(pre-commit): upgrade isort to 5.9.1, use as flake8 plugin
scop Jul 5, 2021
1e85efe
test(pre-commit): upgrade pyupgrade to 2.20.0
scop Jul 5, 2021
ce62ff2
test(pre-commit): upgrade perltidy to 20210625
scop Jul 5, 2021
cd73c1d
test(pre-commit): switch from codespell to typos
scop Jul 5, 2021
a00b719
Merge pull request #532 from scop/feat/ssh-keyscan
scop Jul 6, 2021
bde5676
test(conftest): check error messages in assert_complete()
akinomyoga Jul 5, 2021
1ccebac
fix(contest): expect "rendered_cmd" but not "cmd" in assert_complete()
akinomyoga Jul 7, 2021
b8aab0f
test(convert): check existence of the command
akinomyoga Jul 5, 2021
06b655c
Merge pull request #554 from scop/test/upgrade-dev-deps
scop Jul 7, 2021
074ff4c
style(test): remove redundant require_cmd with require_longopt
scop Jul 31, 2021
3e7d089
Merge pull request #563 from scop/style/test-redundant-require-cmd
scop Aug 1, 2021
af91a70
fix(xmlwf): try _parse_help before _parse_usage
scop Jul 7, 2021
3e55711
feat(xmlwf): add -a and -b arg non-completions
scop Jul 7, 2021
2432551
Merge pull request #558 from scop/xmlwf-improvements
scop Aug 21, 2021
56eeb3e
docs(COPYING): use unmodified upstream license file
a1346054 Aug 18, 2021
d654da8
style(bash_completion): remove redundant quotes
a1346054 Aug 18, 2021
4c9ccad
chore(make-changelog.py): invoke python3 through /usr/bin/env
a1346054 Aug 18, 2021
30ff23c
style(setup-symlinks,docker-script): remove redundant quotes
a1346054 Aug 21, 2021
802d757
style(CONTRIBUTING,README): trim excess whitespace
a1346054 Aug 18, 2021
06581b1
Merge pull request #572 from a1346054/master
scop Aug 21, 2021
4002458
Merge pull request #555 from akinomyoga/check-error-messages-in-asser…
scop Aug 21, 2021
2059ac8
feat(tree): new completion
scop Jul 31, 2021
1fa691a
feat(tree): support long option args separated by equals sign
scop Aug 1, 2021
e88d87c
Merge pull request #566 from scop/feat/tree
scop Aug 21, 2021
2593d54
ci(github): run pushes only on master
scop Aug 22, 2021
7ab2d0a
test(pre-commit): use separate isort hook
scop Aug 22, 2021
d46f19a
Merge pull request #574 from scop/ci/run-on-push-branches
scop Aug 22, 2021
8978317
chore(deps): upgrade shfmt to 3.3.1
scop Aug 22, 2021
a9431f7
Merge pull request #576 from scop/chore/upgrade-shfmt
scop Aug 22, 2021
48e2716
Merge pull request #575 from scop/test/isort-separately
scop Aug 22, 2021
f8220fa
fix(_xinetd_services,aspell,dpkg,etc.): avoid unnecessary word splitting
akinomyoga Jul 7, 2021
f2bec27
fix(_ltrim_colon_completions): do compaction of sparse COMPREPLY
akinomyoga Jul 7, 2021
a086857
fix(secret-tool): fix empty candidates for "secret-tool search" options
akinomyoga Jul 7, 2021
a53a81e
fix(secret-tool): protect unset opts[...] from pathname expansions
akinomyoga Jul 7, 2021
76b7925
fix(nounset): fix nounset errors of -W '${COMPRELY[@]}'
akinomyoga Jul 7, 2021
08dd2cd
fix(nounset): fix nounset errors of -W '${arr[@]}'
akinomyoga Jul 7, 2021
f966e62
fix(tree): work around bash-4.2 bug of [[ ${arr[*]} == *text* ]]
akinomyoga Aug 23, 2021
58889b9
fix(man): work around the case both "manpath" and "man -w" are missing
akinomyoga Aug 23, 2021
3a069dc
test(secret-tool): style: use `split` to create a list for consistency
scop Aug 24, 2021
c2e06e0
Merge pull request #559 from akinomyoga/fix-array-nounset-and-misc
akinomyoga Aug 24, 2021
71700f0
Add renovate.json
renovate-bot Aug 22, 2021
b869513
style(pre-commit): tweak additional_dependencies whitespace for Renovate
scop Aug 22, 2021
8e14127
style(deps): group Python dependencies
scop Aug 22, 2021
933036d
style(deps): tweak dependency specifier whitespace
scop Aug 22, 2021
f1deb65
chore(pre-commit): enable Renovate for venv-run
scop Aug 22, 2021
5db3269
chore(deps): make Python linter dependencies exact versioned
scop Aug 22, 2021
2abe6d6
chore(pre-commit): specify pycodestyle and pyflakes versions for flake8
scop Aug 22, 2021
7c60c04
chore(deps): duplicate some pre-commit ones in dev dependencies
scop Aug 22, 2021
af523d1
ci(renovate): more configuration
scop Aug 22, 2021
aaf4fc0
ci(renovate): empty ignorePaths to make test/ match
scop Aug 23, 2021
796930d
ci(renovate): use `ignorePresets` to remove path ignoring
scop Aug 24, 2021
efd5600
ci(renovate): use `loose` versioning with shellcheck-py
scop Aug 24, 2021
ef5fba6
ci(renovate): use major `regex` versioning with perltidy
scop Aug 24, 2021
60638f6
ci(renovate): group black and flake8 updates
scop Aug 24, 2021
3fe691c
ci(renovate): use PEP 440 version for black and flake pre-commit
scop Aug 24, 2021
94847d0
ci(renovate): follow black releases appropriately
scop Aug 24, 2021
2220079
Merge pull request #577 from scop/renovate/configure
scop Aug 24, 2021
3f78445
chore(deps): update pre-commit/action action to v2.0.3
renovate-bot Aug 24, 2021
5096921
ci(renovate): group isort updates, mark as PEP 440 versioned
scop Aug 24, 2021
374a8c4
chore(deps): update black to v21.7b0
renovate-bot Aug 24, 2021
8d58dbc
chore(pre-commit): update perltidy/perltidy to v20210717
renovate-bot Aug 25, 2021
b7e2a56
chore(pre-commit): update igorshubovych/markdownlint-cli to v0.28.1
renovate-bot Aug 25, 2021
2c5f91b
chore(pre-commit): update isort to v5.9.3
renovate-bot Aug 24, 2021
b649cd1
chore(deps): update mypy to v0.910
renovate-bot Aug 24, 2021
ac480b2
chore(pre-commit): update asottile/pyupgrade to v2.24.0
renovate-bot Aug 24, 2021
62b336c
fix(pylint): `--max-branches` spelling, thanks to `typos
scop Aug 25, 2021
5677f33
ci(renovate): disable dependency dashboard
scop Aug 25, 2021
d85aabd
chore: switch to semantic versioning
scop Aug 26, 2021
f61684a
build(make-changelog): rework to output entire log in markdown
scop Aug 27, 2021
8b2b318
docs(changelog): regenerate markdown one, prune pre-2.0, remove old
scop Aug 27, 2021
3ed7326
ci: add version.txt for release-please-action
scop Aug 26, 2021
a182731
ci: upload tarball artifact
scop Aug 26, 2021
22fe8eb
ci: add release-please-action config
scop Aug 27, 2021
43df32a
ci(release): upload tarball
scop Aug 27, 2021
42c3dbf
refactor(make-changelog): remove, obsoleted by release-please
scop Aug 27, 2021
222c710
feat(sqlite3): add -maxsize arg non-completion
scop Jul 31, 2021
236c5e5
ci: cache non-pre-commit venv PyPI downloads
scop Aug 27, 2021
75a38ca
feat(pylint): message ids completion
scop Jul 31, 2021
93c3d02
feat(okular): complete with markdown files
SuibianP Aug 27, 2021
d599293
test(conftest): make cwd in @pytest.mark.bashcomp relative from fixtures
akinomyoga Jun 30, 2021
2d0ee7c
docs(contributing): note correct commit message format importance
scop Aug 28, 2021
a653fe2
Merge pull request #592 from scop/chore/release-preparations
scop Aug 28, 2021
8e1c83f
ci(pre-commit): switch from action to DIY
scop Aug 28, 2021
1dca1aa
ci(pre-commit): run checks on commit messages
scop Aug 28, 2021
dd7cd8d
ci: rename `check` to `ci`
scop Aug 28, 2021
a4a4b8f
docs(README): point CI badge at GitHub
scop Aug 28, 2021
0955305
ci(Travis): remove config
scop Aug 28, 2021
ccea705
ci(pre-commit): split dep install to a separate step
scop Aug 28, 2021
ccbfa54
ci: add names to our workflow steps
scop Aug 28, 2021
e25da7e
Merge pull request #594 from scop/ci/tweaks
scop Aug 28, 2021
3896f4f
fix(pylint): make message id completion work with < 2.4.0
scop Aug 28, 2021
64be120
test(_parse_help): add failing tests for custom options with failglob
akinomyoga Aug 30, 2021
065e6d1
fix(_parse_help): protect custom help options from pathname expansions
akinomyoga Aug 30, 2021
b6e99e3
test(dd,nproc): use require_longopt (#598)
scop Aug 31, 2021
ea375e3
Merge pull request #601 from akinomyoga/fix-parse_help-for-ssh-comple…
scop Sep 2, 2021
b547097
style(ci): remove redundant `if` expression syntax
scop Sep 2, 2021
4f87ec4
ci: run release-please only on pushes
scop Sep 2, 2021
68606e1
test: elaborate on `require_cmd` xfail implementation details
scop Aug 29, 2021
8a4a499
feat(lrzip): complete long option args
scop Jun 11, 2021
648b6f4
test(_parse_help): add failing tests for {fail,null}glob
akinomyoga Aug 24, 2021
3d70c64
fix(_parse_help): protect word splitting from pathname expansions
akinomyoga Aug 24, 2021
bd8cd5c
test(scp): add failing tests for {fail,null}glob
akinomyoga Jul 5, 2021
835b29a
fix(scp): fix nullglob/failglob errors
akinomyoga Jul 5, 2021
bb95d71
style: explicitly specify the type of "unset" by the option "-v" or "-f"
akinomyoga Sep 7, 2021
2626ce0
style(bash_completion): prefix "_comp_" to tempvars on initialization
akinomyoga Sep 7, 2021
2012047
style(_service): set up completions for services in function
akinomyoga Sep 7, 2021
5f13902
Merge pull request #604 from akinomyoga/style-unset
scop Sep 7, 2021
e869fa3
test(mypy): set mypy_path, to find conftest
scop Sep 7, 2021
ae1a164
fix(_command,_command_offset): missing quotes for command variables
cykerway Sep 8, 2021
c7dcf40
chore(pre-commit): switch from commitlint to gitlint
scop Sep 17, 2021
aa5a326
chore(pre-commit): make use of `default_stages` in commit
scop Sep 17, 2021
04e4d91
ci(renovate): enable pre-commit
scop Sep 18, 2021
27f49bd
chore(pre-commit): switch from markdownlint-cli to pymarkdown
scop Sep 17, 2021
39f584c
chore(pymarkdown): address findings
scop Sep 17, 2021
47c1517
chore(pre-commit): update pymarkdown to v0.9.0
scop Sep 24, 2021
f9146f2
docs(readme): remove known problem related to cd and Makefiles
scop Sep 18, 2021
67d8108
test(ip): require command for route replace test
scop Sep 24, 2021
b6a9ed5
feat(insmod,modinfo,modprobe): support zstd compressed modules (#614)
hramrach Oct 1, 2021
bcec520
test: move docker entrypoint script to test/docker/
scop Oct 7, 2021
8acecbb
test: move .dockerignore to test/
scop Oct 7, 2021
81366d7
test: add Alpine docker build files
scop Oct 7, 2021
03eab0e
test: add CentOS 7 docker build files
scop Oct 7, 2021
e05c21d
test: add Debian 10 docker build files
scop Oct 7, 2021
69f68ee
test: add Fedora development docker build files
scop Oct 7, 2021
020d403
test: add Ubuntu 14 docker build files
scop Oct 7, 2021
e5ebcb2
ci: build and push test Docker images to ghcr.io
scop Oct 8, 2021
32ed36a
test(docker): do not install npm and jshint on ubuntu14
scop Oct 8, 2021
425c551
test(docker): update slapt-get and slapt-get tarball URLs
scop Oct 8, 2021
b6d50c1
refactor(extra): remove obsolete Docker image update git hook scripts
scop Oct 8, 2021
3b01a20
ci: point test images to ghcr.io
scop Oct 8, 2021
09f8870
ci(docker): enable image update on test-cmd-list.txt master changes
scop Oct 8, 2021
9368bb2
ci(docker): update images when their setup files change, too
scop Oct 8, 2021
d416b71
test(debian10): create /var/lib/pkgtools/packages for slapt-get
scop Oct 8, 2021
b21c27f
chore(pre-commit): upgrade shfmt to 3.4.0, use scop/pre-commit-shfmt …
scop Oct 8, 2021
d5001d6
ci(docker): trigger on workflow_dispatch for manual runs
scop Oct 8, 2021
e45c45e
feat(pyston,pyston3): new completion, python alias
scop Oct 8, 2021
1aa6111
feat(python,pyvenv): 3.11 support
scop Oct 8, 2021
386bc5e
feat(python): complete with *.zip
scop Oct 8, 2021
c4bbe33
Merge pull request #620 from scop/chore/ghcr
scop Oct 8, 2021
df99679
ci(renovate): disable Dockerfile updates
scop Oct 8, 2021
c9e0c3c
ci: drop no longer needed Go install
scop Oct 8, 2021
cfa5221
chore(pre-commit): update flake8 to v4
renovate-bot Oct 11, 2021
257a099
chore(deps): update pycodestyle to v2.8.0 (#625)
renovate[bot] Oct 15, 2021
5052fe0
chore(deps): update pyflakes to v2.4.0 (#616)
renovate[bot] Oct 15, 2021
081c757
Merge pull request #626 from scop/renovate/major-flake8
scop Oct 15, 2021
4d6f299
feat(python): tweak -h output for _parse_help to find -bb
scop Oct 20, 2021
979062f
fix(python): nounset mode error with no -X completions
scop Oct 19, 2021
4ccf000
fix(apt-mark): nounset mode error on unknown option
scop Oct 20, 2021
091ad2d
fix(curl): nounset mode error on unknown option
scop Oct 20, 2021
ceb4fdd
fix(avahi-browse): nounset mode error on unknown option
scop Oct 20, 2021
472e0e3
ci(images): re-enable fedoradev build
scop Nov 3, 2021
52206ab
ci(fedoradev): install xargs before attempting to use it
scop Nov 3, 2021
d9e3a53
chore(pre-commit): update shellcheck-py/shellcheck-py to v0.8.0.1
renovate-bot Nov 10, 2021
38150db
fix: address shellcheck SC2295
scop Nov 10, 2021
1a7684c
fix: address shellcheck SC2294
scop Nov 10, 2021
5120657
Merge pull request #650 from scop/renovate/shellcheck-py-shellcheck-p…
scop Nov 11, 2021
7617c08
chore(deps): update black to v21.11b1
renovate-bot Nov 18, 2021
67286c0
chore(black): add py39 and py310 to target-version
scop Nov 18, 2021
e7497f6
Merge pull request #599 from scop/renovate/black
scop Nov 18, 2021
9b535a1
feat(truncate): new completion
scop Nov 18, 2021
a4d4ebc
fix(ip): netns list parsing with netnsids included
remijouannet Nov 15, 2021
b005ba1
test(_command_offset): test changing compspec during meta-completion
potamides Nov 22, 2021
2e9c762
test(_command_offset): add a case that the compspec is unchanged
akinomyoga Nov 25, 2021
7e68b72
fix(_command_offset): handle exit 124 during meta-command completion
potamides Nov 18, 2021
6702ef1
refactor(_command_offset): refactor the retry loop by 124
akinomyoga Nov 20, 2021
befbfc3
fix(_command_offset): discard previous results on retries
akinomyoga Nov 27, 2021
3a4361a
chore(shellcheck): enable deprecate-which
scop Nov 18, 2021
0944a36
chore(shellcheck): enable require-double-brackets
scop Nov 18, 2021
d751b16
chore(shellcheck): remove disable for SC1004
scop Nov 18, 2021
34a73c4
chore(shellcheck): enable and address SC2231
scop Nov 18, 2021
e5a9344
chore(shellcheck): enable and address SC2162
scop Nov 18, 2021
f4e139c
chore(shellcheck): address most SC2015's
scop Nov 18, 2021
a98845f
ci: test on fedoradev again
scop Nov 3, 2021
c12e4da
chore(pre-commit): update jorisroovers/gitlint to v0.17.0
renovate-bot Nov 28, 2021
c18756c
fix(ulimit): do not offer soft/hard/unlimited directly after -S or -H
scop Nov 1, 2021
ecf6f41
fix(ulimit): complete limits only after option that takes one
scop Nov 1, 2021
72b234a
fix(ssh): don't confuse arg counting with option args
scop Nov 7, 2021
e29517d
fix(ssh): do not complete commands if hostnames haven't been specified
scop Nov 30, 2021
bbd773b
style(ssh): sort options the same as in ssh's usage message
scop Nov 30, 2021
c32358b
feat(ssh): add -B arg completion
scop Nov 30, 2021
17c1fab
test(_variables): test index completion under failglob
akinomyoga Dec 13, 2021
503cf7b
fix(_variables): protect from failglob
akinomyoga Dec 13, 2021
b0afc79
Merge pull request #664 from akinomyoga/protect-_variables-from-failglob
scop Dec 13, 2021
c472d58
test(_expand): test with failglob
akinomyoga Dec 22, 2021
0de8dea
fix(_expand): avoid pathname expansions in eval arguments
akinomyoga Dec 22, 2021
6f5ec1b
Merge pull request #670 from akinomyoga/fix-failglob-for-_expand
scop Dec 25, 2021
57d5392
fix(man,info): remove ineffective "_expand" calls
akinomyoga Dec 25, 2021
39baf0f
Merge pull request #672 from akinomyoga/remove-ineffective-_expand
scop Dec 25, 2021
3454034
docs(styleguide): fix asciidoc format
akinomyoga Dec 27, 2021
677362e
Merge pull request #673 from akinomyoga/fix-asciidoc-format
scop Dec 27, 2021
2b6785d
docs: remove "docs/{bashrc,inputrc}"
akinomyoga Dec 27, 2021
a504bdb
docs(*.txt): use atx rather than setext style headers
scop Dec 29, 2021
0602158
docs(main.txt): mark preface as such
scop Dec 29, 2021
9ac8c79
test(pre-commit): add asciidoctor test
scop Dec 29, 2021
4f537c6
Merge pull request #676 from scop/docs/asciidoc
scop Dec 30, 2021
4298bc2
feat(_modules): support zstd compressed modules
richardschuetz Dec 28, 2021
521348d
feat(ssh-keygen): sync -O options with openssh 8.4p1, FIDO arg fixes …
scop Dec 31, 2021
df990b0
docs(tar): move commentary from README to variable and implementation
scop Jan 4, 2022
9357f35
docs(README): remove `cvs` and `configure` items
scop Jan 4, 2022
5b842ff
feat(tar): associate with *.xbps (Void Linux package)
tornaria Jan 23, 2022
242e26c
fix(tar): do not associate with *.gem.<compress-extension>
scop Jan 23, 2022
a66ae99
feat(feh): complete on WebP images
Maelan Jan 7, 2022
a7aabbc
fix: Properly handle environments with unset IFS
Jan 22, 2022
7e7928d
fix(rsync): improve completion by using _parse_help
sbraz Jan 13, 2022
afe81d3
refactor(_umount.linux): remove unnecessary IFS setups
akinomyoga Jan 31, 2022
ec3a250
Merge branch 'master' into dev/osh-release-0.6.pre15
Ruthenic Feb 10, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
18 changes: 9 additions & 9 deletions .dir-locals.el
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
;; bash-completion shell-script mode additional settings for Emacs
;;; Directory Local Variables
;;; For more information see (info "(emacs) Directory Variables")

((sh-mode . ((sh-indent-comment . t)
;; Somewhat fragile, waiting for flycheck-sh-bash-args
(eval . (setq flycheck-command-wrapper-function
(lambda (command)
(append (butlast command 1)
'("-O" "extglob")
(last command)))))
)))
((python-mode
(eval add-hook 'before-save-hook 'blacken-buffer nil t))
(sh-mode
(mode . shfmt-on-save)
(shfmt-arguments "-s")
(flycheck-sh-bash-args "-O" "extglob")
(sh-indent-comment . t)))
9 changes: 9 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,15 @@ charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true
max_line_length = 79
# for shfmt
function_next_line = true
switch_case_indent = true

[Makefile.am]
indent_style = tab

[*.{yml,yaml}]
indent_size = 2

[COMMIT_EDITMSG]
max_line_length = 72
41 changes: 41 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
---
name: Bug report
about: Create a report to help us improve
title: ''
labels: ''
assignees: ''

---

## Describe the bug

<!-- A clear and concise description of what the bug is. -->

## To reproduce

<!-- Steps to reproduce the behavior: -->

1. cd to '...'
2. Type '....'
3. See problem

## Expected behavior

<!-- A clear and concise description of what you expected to happen. -->

## Versions (please complete the following information)

- [ ] Operating system name/distribution and version:
- [ ] bash version, `echo "$BASH_VERSION"`:
- [ ] bash-completion version, `(IFS=.; echo "${BASH_COMPLETION_VERSINFO[*]}")`:

## Additional context

<!-- Add any other context about the problem here. -->

## Debug trace

<!--
See Troubleshooting section in README.md how to generate a debug trace,
copy-paste it into a separate file and attach the file here.
-->
24 changes: 24 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
---
name: Feature request
about: Suggest an idea for this project
title: ''
labels: ''
assignees: ''

---

## Describe the feature/solution

<!-- A clear and concise description of what you want to happen. -->

## Maintenance (please complete the following information)

<!--
See CONTRIBUTING.md, many of the considerations for new completions
applies here, too. If upstream has been asked if they'd be interested in
shipping the completion instead of us here in bash-completion, include
link to the upstream query/issue below.
-->

- [ ] This is a request for new completion
- [ ] Link to upstream project query about shipping the completion:
147 changes: 147 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,147 @@
name: ci

on:
pull_request:
push:
branches:
- master

jobs:
pre-commit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
- uses: actions/cache@v2
with:
path: ~/.cache/pip
key: pip-${{hashFiles('test/requirements*.txt')}}
- uses: actions/cache@v2
with:
path: ~/.cache/pre-commit
key: pre-commit-${{hashFiles('.pre-commit-config.yaml')}}
- name: Install dependencies
run: |
python3 -m venv venv # for venv-run
source venv/bin/activate
python3 -m pip install -Ur test/requirements-dev.txt
- name: Run checks
run: |
source venv/bin/activate

# Commit message checks

tmpdir=$(mktemp -d)
trap "rm -r '$tmpdir'" EXIT
commits_json=$tmpdir/commits.json
commit_txt=$tmpdir/message.txt

# For push, commits are available directly in github.event.commits.
# For pull_request they're not: grab them from API, transform fields
# we want to a similar structure as pushes are.
if [[ "${{github.event.commits}}" ]]; then
cat <<\EOF >"$commits_json"
${{toJSON(github.event.commits)}}
EOF
else
curl -fSsL ${{github.event.pull_request.commits_url}} | \
jq '[.[] | {id: .sha, message: .commit.message}]' >"$commits_json"
fi

git config user.name $(git log -1 --format=format:%an)
git config user.email $(git log -1 --format=format:%ae)
rc=0
for id in $(jq --raw-output '.[].id' <"$commits_json"); do
jq --raw-output ".[] | select(.id==\"$id\") | .message" \
<"$commits_json" >"$commit_txt"
echo "Linting commit $id message..."
set +e
pre-commit run gitlint \
--color=always \
--hook-stage=commit-msg \
--commit-msg-filename="$commit_txt"
((rc+=$?))
set -e
done

# Other pre-commit checks

set +e
pre-commit run --color=always --all-files
((rc+=$?))
set -e

exit $rc

distcheck:
runs-on: ubuntu-latest
strategy:
matrix:
include:
- dist: alpine
- dist: centos7
- dist: debian10
- dist: debian10
bsd: true
network: none
- dist: fedoradev
- dist: ubuntu14
steps:
- uses: actions/checkout@v2
- uses: GoogleCloudPlatform/release-please-action@v2
with:
release-type: simple
id: release
if: github.event_name == 'push' && matrix.dist == 'alpine'
- name: Do release preparations
run: |
version=$(cat version.txt)
sed -i -re "s/^(BASH_COMPLETION_VERSINFO=).*/\\1(${version//./ })/" bash_completion
sed -i -re "s/^(AC_INIT\(.*\[)[0-9.]+(\].*)/\\1$version\\2/" configure.ac
git config user.name $(git log -1 --format=format:%an)
git config user.email $(git log -1 --format=format:%ae)
git commit --message="chore: bump release in dist files" bash_completion configure.ac
git tag --force ${{steps.release.outputs.tag_name}}
git push
git push --tags --force
if: steps.release.outputs.release_created
# A "container" workflow config would be cleaner here, but comes with
# some restrictions/oddities: changes root's $HOME to /github/home
# without changing the actual home dir that can cause some problems,
# and does not provide a way to run with --network none.
# fedoradev unconfined: https://bugzilla.redhat.com/1900021
- name: Run main build
run: >-
docker run
--rm
--tty
--env CI=true
--env DIST=${{matrix.dist}}
--env BSD=${{matrix.bsd}}
--env PYTESTFLAGS=--verbose
--env NETWORK=$NETWORK
${NETWORK:+--network $NETWORK}
$(test $DIST = fedoradev && echo --security-opt seccomp=unconfined)
--volume $PWD:/usr/src/bash-completion
--workdir /usr/src/bash-completion
ghcr.io/scop/bash-completion/test:${{matrix.dist}}
test/docker/entrypoint.sh
env:
DIST: ${{matrix.dist}}
NETWORK: ${{matrix.network}}
- name: Upload release assets
run: |
set -x
upload_url="${{steps.release.outputs.upload_url}}"
tarball="bash-completion-$(cat version.txt).tar.xz"
curl \
--header "Authorization: Bearer ${{secrets.GITHUB_TOKEN}}" \
--header "Accept: application/vnd.github.v3+json" \
--header "Content-Type: application/x-xz-compressed-tar" \
--data-binary "@$tarball" \
"${upload_url%{*}?name=$tarball"
if: steps.release.outputs.release_created
- uses: actions/upload-artifact@v2
with:
path: bash-completion-*.tar.xz
if: matrix.dist == 'alpine'
43 changes: 43 additions & 0 deletions .github/workflows/update-docker-images.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: update-docker-images

# Update Docker images when the set of commands required present for testing
# change. This is not perfect as it would be good to have the new commands
# installed already at PR time, and at least at time the change lands in the
# default branch. That way it'd be tested immediately then with images
# containing it, instead of later along with some other, completely unrelated
# change.

on:
push:
paths:
- test/test-cmd-list.txt
- test/docker/*/Dockerfile
- test/docker/*/install-packages.sh
workflow_dispatch:

jobs:
update-test-image:
runs-on: ubuntu-latest
if: github.repository_owner == 'scop' && github.ref == 'refs/heads/master'
strategy:
matrix:
include:
- dist: alpine
- dist: centos7
- dist: debian10
- dist: fedoradev
- dist: ubuntu14
steps:
- uses: actions/checkout@v2
- uses: docker/login-action@v1
with:
registry: ghcr.io
username: ${{github.repository_owner}}
password: ${{secrets.GITHUB_TOKEN}}
- uses: docker/build-push-action@v2
with:
context: test
file: test/docker/${{matrix.dist}}/Dockerfile
tags: |
ghcr.io/scop/bash-completion/test:${{matrix.dist}}
push: true
35 changes: 19 additions & 16 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,20 +1,23 @@
*.tar*
*.swp
*.tar*
*~
.pytest_cache/
Makefile
Makefile.in
aclocal.m4
autom4te.cache
config.log
config.status
configure
install-sh
missing
doc/*.xml
*~
doc/html*
bash_completion.sh
bash-completion.pc
bash-completion-config.cmake
bash-completion-config-version.cmake
__pycache__/
.pytest_cache/
pytestdebug.log
/.python-version
/aclocal.m4
/autom4te.cache
/bash-completion-config-version.cmake
/bash-completion-config.cmake
/bash-completion.pc
/bash_completion.sh
/config.log
/config.status
/configure
/configure.lineno
/doc/*.xml
/doc/html*
/install-sh
/missing
10 changes: 10 additions & 0 deletions .gitlint
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
[general]
ignore = body-is-missing
ignore-fixup-commits = false
ignore-revert-commits = false
ignore-squash-commits = false
ignore-stdin = true
contrib = contrib-title-conventional-commits

[ignore-body-lines]
regex = ^(Co-authored-by:|(Refs )?https?://)
6 changes: 6 additions & 0 deletions .perltidyrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
--perl-best-practices
--maximum-line-length=79
--paren-tightness=2
--cuddled-else
--warning-output
--converge
Loading