scripts.git
12 months agoFix ssl_mgmt after openssl -text output change master
Thomas Preud'homme [Thu, 31 May 2018 19:22:06 +0000 (20:22 +0100)]
Fix ssl_mgmt after openssl -text output change

The output of openssl x509 -text changed from lines like:

O=foo/OU=bar

to lines like:

O = foo, OU = bar

This commit adapts the code to that change. TODO: A machine readable
output ought to be used instead.

13 months ago[cluster] convert README to MarkDown
mcy [Fri, 18 May 2018 14:39:02 +0000 (16:39 +0200)]
[cluster] convert README to MarkDown

13 months agoREADME: list scripts of interest
Matteo Cypriani [Fri, 4 May 2018 11:23:02 +0000 (13:23 +0200)]
README: list scripts of interest

13 months agoAdd dddoc/
Matteo Cypriani [Fri, 4 May 2018 11:05:56 +0000 (13:05 +0200)]
Add dddoc/

14 months ago[wifi] capture-sample: shellcheck & checkbashisms
Matteo Cypriani [Fri, 13 Apr 2018 18:21:03 +0000 (20:21 +0200)]
[wifi] capture-sample: shellcheck & checkbashisms

14 months ago[file_utils] fix python shebang & run prospector
Matteo Cypriani [Thu, 12 Apr 2018 16:34:51 +0000 (18:34 +0200)]
[file_utils] fix python shebang & run prospector

prospector is still complaining about bare excepts in unln.py.

14 months ago[textproc] shellcheck
Matteo Cypriani [Wed, 11 Apr 2018 21:32:56 +0000 (23:32 +0200)]
[textproc] shellcheck

14 months ago[graphics] shellcheck bypass
Matteo Cypriani [Wed, 11 Apr 2018 21:30:46 +0000 (23:30 +0200)]
[graphics] shellcheck bypass

14 months ago[git] shellcheck, minor changes
Matteo Cypriani [Wed, 11 Apr 2018 21:28:36 +0000 (23:28 +0200)]
[git] shellcheck, minor changes

14 months ago[debian] fix grep_dd_sigs & shellcheck
Matteo Cypriani [Wed, 11 Apr 2018 21:07:45 +0000 (23:07 +0200)]
[debian] fix grep_dd_sigs & shellcheck

Without quoting "$sigs", this was making the script output nothing:
    echo $sigs | while read

14 months ago[cluster] minor improvements & shellcheck
Matteo Cypriani [Wed, 11 Apr 2018 20:56:01 +0000 (22:56 +0200)]
[cluster] minor improvements & shellcheck

14 months ago[backup] shellcheck
Matteo Cypriani [Wed, 11 Apr 2018 20:31:14 +0000 (22:31 +0200)]
[backup] shellcheck

14 months agometaflac-field2field: minor improvements, shellcheck
Matteo Cypriani [Wed, 11 Apr 2018 20:11:11 +0000 (22:11 +0200)]
metaflac-field2field: minor improvements, shellcheck

14 months agometaflac-field2field: reindent with 4 spaces
Matteo Cypriani [Wed, 11 Apr 2018 19:48:55 +0000 (21:48 +0200)]
metaflac-field2field: reindent with 4 spaces

14 months agomp3car: use printf instead of echo
Matteo Cypriani [Wed, 11 Apr 2018 19:47:10 +0000 (21:47 +0200)]
mp3car: use printf instead of echo

14 months agojust-play-something: reindent, shellcheck
Matteo Cypriani [Wed, 11 Apr 2018 19:46:47 +0000 (21:46 +0200)]
just-play-something: reindent, shellcheck

14 months ago[archivers] shellcheck
Matteo Cypriani [Wed, 11 Apr 2018 19:30:19 +0000 (21:30 +0200)]
[archivers] shellcheck

14 months agolz: reindent with 4 spaces
Matteo Cypriani [Wed, 11 Apr 2018 19:22:07 +0000 (21:22 +0200)]
lz: reindent with 4 spaces

14 months agomvparent: rename variables, shellcheck
Matteo Cypriani [Wed, 11 Apr 2018 19:09:21 +0000 (21:09 +0200)]
mvparent: rename variables, shellcheck

14 months agomvparent: reindent with 4 spaces
Matteo Cypriani [Wed, 11 Apr 2018 18:59:48 +0000 (20:59 +0200)]
mvparent: reindent with 4 spaces

14 months agoAdd file_utils/prefixsubdirs.sh
Matteo Cypriani [Wed, 11 Apr 2018 18:55:01 +0000 (20:55 +0200)]
Add file_utils/prefixsubdirs.sh

15 months agoAdd misc/searchproviders2html.sh
Matteo Cypriani [Sun, 25 Feb 2018 20:30:01 +0000 (21:30 +0100)]
Add misc/searchproviders2html.sh

20 months agotiff-batch-convert: quality is now an argument
Matteo Cypriani [Fri, 6 Oct 2017 14:31:03 +0000 (10:31 -0400)]
tiff-batch-convert: quality is now an argument

20 months agoMore markdownification of READMEs
Matteo Cypriani [Sat, 23 Sep 2017 04:27:51 +0000 (00:27 -0400)]
More markdownification of READMEs

20 months agoMerge latex and make_html2text into textproc
Matteo Cypriani [Sat, 23 Sep 2017 03:41:26 +0000 (23:41 -0400)]
Merge latex and make_html2text into textproc

20 months ago[graphics] Add tiff-batch-convert.sh
Matteo Cypriani [Sat, 23 Sep 2017 03:30:51 +0000 (23:30 -0400)]
[graphics] Add tiff-batch-convert.sh

20 months agoSplit multimedia into audio and graphics
Matteo Cypriani [Fri, 22 Sep 2017 20:58:29 +0000 (16:58 -0400)]
Split multimedia into audio and graphics

Also to mimic pkgsrc categories.

While there:
- Convert the READMEs to MarkDown to make forges happier.
- Split French README section to audio/README-fr.md.
- Rewrap READMEs at 80 characters.

20 months agoRename compression_utils -> archivers
Matteo Cypriani [Fri, 22 Sep 2017 20:50:25 +0000 (16:50 -0400)]
Rename compression_utils -> archivers

Mimics pkgsrc categories.

20 months agoAdd TODOs
Matteo Cypriani [Fri, 22 Sep 2017 20:45:16 +0000 (16:45 -0400)]
Add TODOs

20 months agoImprove READMEs
Matteo Cypriani [Fri, 22 Sep 2017 20:44:57 +0000 (16:44 -0400)]
Improve READMEs

2 years agoConvert README to Markdown (README.md)
Matteo Cypriani [Tue, 1 Nov 2016 20:34:23 +0000 (16:34 -0400)]
Convert README to Markdown (README.md)

2 years ago[multimedia] README: note about lowercase FLAC fields
Matteo Cypriani [Thu, 13 Oct 2016 16:47:32 +0000 (12:47 -0400)]
[multimedia] README: note about lowercase FLAC fields

2 years ago[multimedia] metaflac-field2field: clarifications
Matteo Cypriani [Thu, 13 Oct 2016 16:46:06 +0000 (12:46 -0400)]
[multimedia] metaflac-field2field: clarifications

Improved top comment and usage message (move/rename).
Added some extra debug messages.

3 years ago[multimedia] Add apply-exif-orientation.sh
Matteo Cypriani [Fri, 22 Jan 2016 14:19:18 +0000 (15:19 +0100)]
[multimedia] Add apply-exif-orientation.sh

3 years ago[file_utils] mvparent: don't overwrite files
Matteo Cypriani [Fri, 22 Jan 2016 13:53:52 +0000 (14:53 +0100)]
[file_utils] mvparent: don't overwrite files

Use mv's -n option to avoid overwriting files.

4 years ago[ssl_mgmt] Set ownership and rights of keycert
Thomas Preud'homme [Tue, 4 Nov 2014 23:01:00 +0000 (23:01 +0000)]
[ssl_mgmt] Set ownership and rights of keycert

4 years ago[ssl_mgmt] Set CA:FALSE constraint for certs
Thomas Preud'homme [Tue, 4 Nov 2014 22:18:42 +0000 (22:18 +0000)]
[ssl_mgmt] Set CA:FALSE constraint for certs

4 years ago[ssl_mgmt] Install cert before taking its hash
Thomas Preud'homme [Fri, 12 Sep 2014 14:04:58 +0000 (22:04 +0800)]
[ssl_mgmt] Install cert before taking its hash

Install the certificate before taking the fingerprint of the installed
certificate for mailing the administrators.

4 years ago[ssl_mgmt] Ensure version 3 certificate are used
Thomas Preud'homme [Fri, 12 Sep 2014 14:04:58 +0000 (22:04 +0800)]
[ssl_mgmt] Ensure version 3 certificate are used

4 years ago[ssl_mgmt] Create workdir before running tests
Thomas Preud'homme [Fri, 12 Sep 2014 13:52:18 +0000 (21:52 +0800)]
[ssl_mgmt] Create workdir before running tests

4 years ago[xzize] Use default (not max) compression level
Matteo Cypriani [Wed, 10 Sep 2014 15:05:51 +0000 (11:05 -0400)]
[xzize] Use default (not max) compression level

It's not recommended to always use -9 with xz.

4 years ago[compression_utils] Document existence of atool
Matteo Cypriani [Wed, 10 Sep 2014 14:52:55 +0000 (10:52 -0400)]
[compression_utils] Document existence of atool

5 years ago[file_utils] README: add note about CD-R capacity
Matteo Cypriani [Tue, 3 Jun 2014 01:20:35 +0000 (21:20 -0400)]
[file_utils] README: add note about CD-R capacity

5 years ago[file_utils] dirpacker: --first-bin-number
Matteo Cypriani [Mon, 2 Jun 2014 02:41:58 +0000 (22:41 -0400)]
[file_utils] dirpacker: --first-bin-number

The option --first-bin-number (-n) allows to select the number at which
the numbering of the volumes starts.

5 years ago[file_utils] dirpacker: fix verbose list printing
Matteo Cypriani [Mon, 2 Jun 2014 01:53:42 +0000 (21:53 -0400)]
[file_utils] dirpacker: fix verbose list printing

5 years ago[file_utils] unln: typos
Matteo Cypriani [Mon, 2 Jun 2014 01:46:29 +0000 (21:46 -0400)]
[file_utils] unln: typos

5 years ago[file_utils] dirpacker: --machine-readable
Matteo Cypriani [Mon, 2 Jun 2014 01:43:27 +0000 (21:43 -0400)]
[file_utils] dirpacker: --machine-readable

The option --machine-readable allows to print the list of bins in a
machine-readable format.

5 years ago[file_utils] dirpacker: rework message printing
Matteo Cypriani [Mon, 2 Jun 2014 01:26:00 +0000 (21:26 -0400)]
[file_utils] dirpacker: rework message printing

5 years ago[file_utils] dirpacker: --move, --prefix, -v/-q
Matteo Cypriani [Mon, 2 Jun 2014 00:48:06 +0000 (20:48 -0400)]
[file_utils] dirpacker: --move, --prefix, -v/-q

dirpacker can now create a directory for each volume and move the
corresponding files in it (option --move).

The option --prefix allows the user to specify a custom prefix for the
volumes' names.

The options -v (--verbose) and -q (--quiet) enable or disable displaying
the list of volumes.

5 years ago[file_utils] mvparent: allow multiple arguments
Matteo Cypriani [Mon, 2 Jun 2014 00:38:55 +0000 (20:38 -0400)]
[file_utils] mvparent: allow multiple arguments

5 years ago[file_utils] dirpacker: refactoring (class Bin)
Matteo Cypriani [Sat, 31 May 2014 22:57:00 +0000 (18:57 -0400)]
[file_utils] dirpacker: refactoring (class Bin)

5 years ago[file_utils] Add dirpacker.py
Matteo Cypriani [Sat, 31 May 2014 19:42:24 +0000 (15:42 -0400)]
[file_utils] Add dirpacker.py

This program helps grouping a bunch of files into fixed-size volumes
(e.g. to burn them on CD-ROMs).

5 years ago[multimedia] Add mp3car.sh
Matteo Cypriani [Fri, 30 May 2014 18:51:29 +0000 (14:51 -0400)]
[multimedia] Add mp3car.sh

Utility to convert audio files to low-quality MP3s.

5 years agoFix some typos; add TODO for just-play-something
Matteo Cypriani [Fri, 30 May 2014 18:36:40 +0000 (14:36 -0400)]
Fix some typos; add TODO for just-play-something

5 years ago[ssl_mgmt] Sign email sent to notifiedUsers
Thomas Preud'homme [Mon, 19 May 2014 13:25:52 +0000 (21:25 +0800)]
[ssl_mgmt] Sign email sent to notifiedUsers

5 years ago[ssl_mgmt] Use nobody to test email
Thomas Preud'homme [Mon, 19 May 2014 13:11:28 +0000 (21:11 +0800)]
[ssl_mgmt] Use nobody to test email

nobody should be present on most (all?) unix system and is thus better
for test. However it's still not ideal as it might be connected to an
account that is not the one running the testsuite and the mail might
surprise that user.

5 years ago[ssl_mgmt] Add a TODO file
Thomas Preud'homme [Sun, 11 May 2014 07:42:02 +0000 (15:42 +0800)]
[ssl_mgmt] Add a TODO file

5 years ago[ssl_mgmt] group cmd to set ownership+rights
Thomas Preud'homme [Sun, 11 May 2014 07:00:49 +0000 (15:00 +0800)]
[ssl_mgmt] group cmd to set ownership+rights

5 years ago[ssl_mgmt] Add tests for sanity checks
Thomas Preud'homme [Sun, 11 May 2014 06:34:10 +0000 (14:34 +0800)]
[ssl_mgmt] Add tests for sanity checks

5 years ago[ssl_mgmt] Only set ownership & rights if gen ok
Thomas Preud'homme [Sun, 11 May 2014 06:23:45 +0000 (14:23 +0800)]
[ssl_mgmt] Only set ownership & rights if gen ok

Only set ownership and rights if generated file are not corrupted and
certificate match the private key.

5 years ago[ssl_mgmt] Add automated testsuite
Thomas Preud'homme [Sun, 11 May 2014 04:09:55 +0000 (12:09 +0800)]
[ssl_mgmt] Add automated testsuite

5 years ago[ssl_mgmt] Exit if missing file or rights
Thomas Preud'homme [Sun, 11 May 2014 04:07:34 +0000 (12:07 +0800)]
[ssl_mgmt] Exit if missing file or rights

5 years ago[ssl_mgmt] Add some sanity checks
Thomas Preud'homme [Tue, 6 May 2014 12:57:11 +0000 (20:57 +0800)]
[ssl_mgmt] Add some sanity checks

Check openssl can read both certificate and key and that they match each
other.

5 years ago[cluster] Support XDG Base Directory Specification
Matteo Cypriani [Sat, 22 Mar 2014 17:06:33 +0000 (13:06 -0400)]
[cluster] Support XDG Base Directory Specification

Use $XDG_CONFIG_HOME if set, instead of $HOME/.config.

5 years ago[cluster] cluster-deploy: check cluster-ping dep.
Matteo Cypriani [Sat, 22 Mar 2014 16:22:46 +0000 (12:22 -0400)]
[cluster] cluster-deploy: check cluster-ping dep.

Make sure cluster-ping is present along with cluster-deploy.

5 years ago[ssl_mgmt] Send all warning echo to stderr
Thomas Preud'homme [Mon, 5 May 2014 15:39:38 +0000 (23:39 +0800)]
[ssl_mgmt] Send all warning echo to stderr

Fix echos introduced 2 commits ago with parts of the messages sent to
stdout and the other parts to stderr.

5 years ago[ssl_mgmt] Update documentation
Thomas Preud'homme [Mon, 5 May 2014 14:44:35 +0000 (22:44 +0800)]
[ssl_mgmt] Update documentation

5 years ago[ssl_mgmt] Change default to sane values
Thomas Preud'homme [Sun, 4 May 2014 14:32:44 +0000 (22:32 +0800)]
[ssl_mgmt] Change default to sane values

Now that our installation was migrating to saner places, change default
values.

5 years ago[ssl_mgmt] Fix copying of user/group ownership
Thomas Preud'homme [Sun, 4 May 2014 15:23:16 +0000 (23:23 +0800)]
[ssl_mgmt] Fix copying of user/group ownership

5 years ago[ssl_mgmt] Send email with new fingerprints
Thomas Preud'homme [Sat, 3 May 2014 13:32:11 +0000 (21:32 +0800)]
[ssl_mgmt] Send email with new fingerprints

5 years agoAdd simple test infrastructure
Thomas Preud'homme [Sat, 3 May 2014 10:12:11 +0000 (18:12 +0800)]
Add simple test infrastructure

5 years ago[ssl_mgmt] Fail instead of sudo if rights not ok
Thomas Preud'homme [Sat, 3 May 2014 09:53:38 +0000 (17:53 +0800)]
[ssl_mgmt] Fail instead of sudo if rights not ok

5 years ago[ssl_mgmt] Add debian-admin openssl howto
Thomas Preud'homme [Sat, 3 May 2014 08:47:39 +0000 (16:47 +0800)]
[ssl_mgmt] Add debian-admin openssl howto

Add debian-admin article used as main documentation for developing this
script into the repository to be able to develop offline.

5 years ago[ssl_mgmt] Stop hardcoding path
Thomas Preud'homme [Sat, 3 May 2014 07:40:11 +0000 (15:40 +0800)]
[ssl_mgmt] Stop hardcoding path

Replace hardcoded paths by a bunch of variables with default values and
that can be set from a configuration file. This should make testing much
more easy.

5 years ago[ssl_mgmt] Use SHA1 as default hash instead of MD5
Thomas Preud'homme [Tue, 29 Apr 2014 16:24:58 +0000 (00:24 +0800)]
[ssl_mgmt] Use SHA1 as default hash instead of MD5

5 years ago[ssl_mgmt] Comment out extensions with empty value
Thomas Preud'homme [Tue, 29 Apr 2014 14:21:05 +0000 (22:21 +0800)]
[ssl_mgmt] Comment out extensions with empty value

5 years ago[ssl_mgmt] Fix subject alternative name detection
Thomas Preud'homme [Sun, 9 Mar 2014 13:00:24 +0000 (21:00 +0800)]
[ssl_mgmt] Fix subject alternative name detection

5 years ago[ssl_mgmt] Add option to avoid overwrite
Thomas Preud'homme [Sun, 9 Mar 2014 10:56:21 +0000 (18:56 +0800)]
[ssl_mgmt] Add option to avoid overwrite

5 years ago[ssl_mgmt] Add comments to functions missing one
Thomas Preud'homme [Sun, 9 Mar 2014 10:30:27 +0000 (18:30 +0800)]
[ssl_mgmt] Add comments to functions missing one

5 years ago[ssl_mgmt] Alert user if no overwrite occur
Thomas Preud'homme [Sun, 9 Mar 2014 10:25:20 +0000 (18:25 +0800)]
[ssl_mgmt] Alert user if no overwrite occur

5 years ago[ssl_mgmt] copy access right from existing file
Thomas Preud'homme [Sun, 9 Mar 2014 10:18:58 +0000 (18:18 +0800)]
[ssl_mgmt] copy access right from existing file

5 years ago[ssl_mgmt] Fix support for empty field values
Thomas Preud'homme [Sun, 9 Mar 2014 09:16:27 +0000 (17:16 +0800)]
[ssl_mgmt] Fix support for empty field values

5 years ago[ssl_mgmt] Only overwrite openssl.cnf when ready
Thomas Preud'homme [Sun, 9 Mar 2014 09:57:35 +0000 (17:57 +0800)]
[ssl_mgmt] Only overwrite openssl.cnf when ready

5 years ago[ssl_mgmt] Fix usage of EDITOR
Thomas Preud'homme [Sun, 9 Mar 2014 08:54:29 +0000 (16:54 +0800)]
[ssl_mgmt] Fix usage of EDITOR

5 years ago[ssl_mgmt] Allow to specify a cert file
Thomas Preud'homme [Sun, 9 Mar 2014 08:54:06 +0000 (16:54 +0800)]
[ssl_mgmt] Allow to specify a cert file

5 years ago[ssl_mgmt] Add option to only generate openssl.cnf
Thomas Preud'homme [Sun, 9 Mar 2014 08:22:54 +0000 (16:22 +0800)]
[ssl_mgmt] Add option to only generate openssl.cnf

5 years ago[ssl_mgmt] Change pattern delimiter: s/#/@/
Thomas Preud'homme [Sun, 9 Mar 2014 08:08:41 +0000 (16:08 +0800)]
[ssl_mgmt] Change pattern delimiter: s/#/@/

6 years ago[cluster] Test the existence of the hosts' list
Matteo Cypriani [Mon, 20 May 2013 18:46:39 +0000 (14:46 -0400)]
[cluster] Test the existence of the hosts' list

We now test if the hosts' list file exists before to work on it.

6 years ago[cluster] deploy: skip non-existing files
Matteo Cypriani [Mon, 20 May 2013 18:36:02 +0000 (14:36 -0400)]
[cluster] deploy: skip non-existing files

In "one-by-one" mode, test the existence of a file before to try to
transfer it.

6 years ago[cluster] deploy: fix destination directory
Matteo Cypriani [Mon, 20 May 2013 18:35:49 +0000 (14:35 -0400)]
[cluster] deploy: fix destination directory

"~" is resolved by the local shell (dumb me!). We now get the
destination directory by connecting to the first alive host from the
hosts' list (using cluster-ping), and get the user's home directory.
This is not perfect because it assumes the home directory is the same on
each host.

We could add an option in the future to do the test on each host, but
this would be significantly slower. Alternatively, we could allow to use
scp instead of pscp (because scp is smart enough to get the remote
user's home directory by itself), transferring files once at time, but
again, it would be slow.

6 years ago[cluster] deploy: add -r and -R options (rsync)
Matteo Cypriani [Thu, 2 May 2013 16:17:22 +0000 (12:17 -0400)]
[cluster] deploy: add -r and -R options (rsync)

The -r option allows to use prsync instead of pscp. The -R option is the
same, except the --delete option is passed to rsync.

6 years ago[cluster] deploy: add -P option
Matteo Cypriani [Thu, 2 May 2013 15:18:24 +0000 (11:18 -0400)]
[cluster] deploy: add -P option

The -P option allows to transfer the files in parallel rather than one
by one.

6 years ago[cluster] deploy: send to user's home
Matteo Cypriani [Thu, 2 May 2013 14:57:30 +0000 (10:57 -0400)]
[cluster] deploy: send to user's home

Set the destination directory to ~ instead of /root.

6 years ago[cluster] Give up using getopt
Matteo Cypriani [Thu, 2 May 2013 14:56:28 +0000 (10:56 -0400)]
[cluster] Give up using getopt

getopt prevents using spaces in the arguments.

6 years ago[cluster] Don't force root login any more
Matteo Cypriani [Wed, 1 May 2013 20:12:09 +0000 (16:12 -0400)]
[cluster] Don't force root login any more

The login was hard-coded to root, this was fixed to use by default the
local login name. The option -l was added to allow to specify a
different login name.

6 years agoAdd cluster utilities
Matteo Cypriani [Mon, 29 Apr 2013 20:43:41 +0000 (16:43 -0400)]
Add cluster utilities

6 years ago[multimedia] j-p-s: fix typo, add a tip, symlink
Matteo Cypriani [Fri, 26 Apr 2013 04:32:28 +0000 (00:32 -0400)]
[multimedia] j-p-s: fix typo, add a tip, symlink

Fix a dumb typo in just-play-something.sh, improve the README with a
new tip, and add a symbolic link in the bin/ directory.

6 years ago[multimedia] Add just-play-something.sh
Matteo Cypriani [Fri, 26 Apr 2013 04:01:53 +0000 (00:01 -0400)]
[multimedia] Add just-play-something.sh

MPC/MPD script to start playing "just something".

6 years ago[multimedia] Translate metaflac-field2field.sh
Matteo Cypriani [Fri, 26 Apr 2013 03:34:30 +0000 (23:34 -0400)]
[multimedia] Translate metaflac-field2field.sh

6 years ago[multimedia] Translate and improve README
Matteo Cypriani [Fri, 26 Apr 2013 03:16:33 +0000 (23:16 -0400)]
[multimedia] Translate and improve README