Skip to content

Commit

Permalink
feat: detect error on sh scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
m-maillot committed Nov 7, 2023
1 parent b4e11fb commit 47d9c3a
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 1 deletion.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
"lint": "eslint src/ --ext .ts --fix",
"test": "CDTN_API_URL=https://code-du-travail-numerique-preprod.dev.fabrique.social.gouv.fr jest",
"test-one": "jest analysis --watch",
"monolog": "node -r ts-node/register --max-old-space-size=28000 src/bin/index.ts",
"monolog": "node -r ts-node/register --max-old-space-size=45000 src/bin/index.ts",
"build": "yarn run build:bin && yarn run build:lib",
"build:bin": "yarn run ncc build src/bin/index.ts -o bin",
"build:lib": "yarn tsc -p src/tsconfig.lib.json",
Expand Down
3 changes: 3 additions & 0 deletions scripts/download_dump.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
#!/bin/bash

# Exit on error
set -e

mkdir data

date=`date -d "@$(($(date +%s) - 86400))" "+%Y-%m-%d"`
Expand Down
3 changes: 3 additions & 0 deletions scripts/download_dump_precise_date.sh
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
#!/bin/bash

# Exit on error
set -e

mkdir data

date=$1
Expand Down
4 changes: 4 additions & 0 deletions scripts/dump_matomo_precise_date.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
#!/bin/bash

# Exit on error
set -e

limit=100
offset=0
accu="[]"
Expand Down
4 changes: 4 additions & 0 deletions scripts/dump_matomo_yesterday.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
#!/bin/bash

# Exit on error
set -e

date=`date -d "@$(($(date +%s) - 86400))" "+%Y-%m-%d"`
# date=`gdate -d "@$(($(gdate +%s) - 86400))" "+%Y-%m-%d"` # to run locally on macosx
# date=2021-11-02
Expand Down
3 changes: 3 additions & 0 deletions scripts/get_last_month_cache.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
#!/bin/bash

# Exit on error
set -e

DATA_FOLDER="data-queries"

if [ -z "$1" ]; then
Expand Down

0 comments on commit 47d9c3a

Please sign in to comment.