fix: Cleaned up the export.sh script from extraneous documentation and a useless empty echo.

This commit is contained in:
Rick van Lieshout 2023-03-20 09:37:12 +01:00
parent 78d6aa847c
commit 5003ae16c3
3 changed files with 9 additions and 4 deletions

View File

@ -5,6 +5,14 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [1.1.1]
Cleaned up the export.sh script from extraneous documentation and a useless empty echo.
## [1.1.0]
Added the ability to use a different password for the encrypted output
## [1.0.0] ## [1.0.0]
Initial version of the export script Initial version of the export script

View File

@ -1,7 +1,5 @@
#!/usr/bin/env bash #!/usr/bin/env bash
# input password might be encrypted/hashed/etc
set -e set -e
export LC_CTYPE=C export LC_CTYPE=C
export LC_ALL=C export LC_ALL=C
@ -57,7 +55,6 @@ BW_SESSION=$(bw login "$BW_ACCOUNT" "$BW_INTERNAL_PASSWORD" --raw)
# commands # commands
echo "Exporting to \"$BW_ENC_OUTPUT_FILE\"" echo "Exporting to \"$BW_ENC_OUTPUT_FILE\""
echo "$BW_ENCRYPTION_PASSWORD"
bw --raw --session "$BW_SESSION" export --format json | openssl enc $BW_OPENSSL_OPTIONS -k "$BW_INTERNAL_ENCRYPTION_PASS" -out "$BW_ENC_OUTPUT_FILE" bw --raw --session "$BW_SESSION" export --format json | openssl enc $BW_OPENSSL_OPTIONS -k "$BW_INTERNAL_ENCRYPTION_PASS" -out "$BW_ENC_OUTPUT_FILE"
bw_logout bw_logout

View File

@ -1,6 +1,6 @@
{ {
"name": "bw-export", "name": "bw-export",
"version": "1.1.0", "version": "1.1.1",
"description": "bw-export is a simple bash script that exports a raw, encrypted JSON copy of your Bitwarden vault.", "description": "bw-export is a simple bash script that exports a raw, encrypted JSON copy of your Bitwarden vault.",
"main": "export.sh", "main": "export.sh",
"scripts": { "scripts": {