Skip to content

Commit

Permalink
Merge #274: Clean sqlite bash commands
Browse files Browse the repository at this point in the history
891a744 fix: clean sqlite bash commands (Jose Celano)

Pull request description:

  I forgot some changes in the previous [PR](#270).

Top commit has no ACKs.

Tree-SHA512: 5a44e6f8979db9109650341cf510162c9a0dee786fc5baca2fa4d9f80fe8c920b4004829b4d36fc5be1b8c728c0130ec2766ba07f62e6a94eef1edb4c1badd6a
  • Loading branch information
josecelano committed Sep 11, 2023
2 parents 158757b + 891a744 commit f493964
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
12 changes: 6 additions & 6 deletions bin/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,13 @@ mkdir -p "./storage/database"

# Generate the sqlite database for the index backend if it does not exist
if ! [ -f "./storage/database/data.db" ]; then
# todo: it should get the path from config.toml and only do it when we use sqlite
touch ./storage/database/data.db
echo ";" | sqlite3 ./storage/database/data.db
sqlite3 ./storage/database/data.db "VACUUM;"
fi

# Generate storage directory if it does not exist
mkdir -p "./storage/tracker/lib/database"

# Generate the sqlite database for the tracker if it does not exist
if ! [ -f "./storage/database/tracker.db" ]; then
touch ./storage/database/tracker.db
echo ";" | sqlite3 ./storage/database/tracker.db
if ! [ -f "./storage/tracker/lib/database/sqlite3.db" ]; then
sqlite3 ./storage/tracker/lib/database/sqlite3.db "VACUUM;"
fi
1 change: 0 additions & 1 deletion docker/bin/e2e/sqlite/e2e-env-reset.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ mkdir -p "./storage/database"

# Generate the sqlite database for the index backend if it does not exist
if ! [ -f "./storage/database/torrust_index_backend_e2e_testing.db" ]; then
# todo: it should get the path from config.toml and only do it when we use sqlite
sqlite3 ./storage/database/torrust_index_backend_e2e_testing.db "VACUUM;"
fi

Expand Down

0 comments on commit f493964

Please sign in to comment.