{"id":21711317,"url":"https://github.com/michelemartone/dabo","last_synced_at":"2026-05-18T08:06:20.253Z","repository":{"id":130828279,"uuid":"234342798","full_name":"michelemartone/dabo","owner":"michelemartone","description":"Did Anything Break Overnight? : minimalistic shell scripts unit-testing","archived":false,"fork":false,"pushed_at":"2021-04-19T21:02:12.000Z","size":131,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-20T18:17:39.174Z","etag":null,"topics":["bash","bash-script","command-line-tool","cron-jobs","feedback","minimalist","modulefiles","nohup","reporting-tool","shell-script","testing-tool","unit-testing"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/michelemartone.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-01-16T14:51:19.000Z","updated_at":"2023-09-08T18:02:21.000Z","dependencies_parsed_at":"2023-03-17T06:00:56.610Z","dependency_job_id":null,"html_url":"https://github.com/michelemartone/dabo","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/michelemartone/dabo","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/michelemartone%2Fdabo","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/michelemartone%2Fdabo/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/michelemartone%2Fdabo/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/michelemartone%2Fdabo/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/michelemartone","download_url":"https://codeload.github.com/michelemartone/dabo/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/michelemartone%2Fdabo/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33170447,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-18T05:43:36.989Z","status":"ssl_error","status_checked_at":"2026-05-18T05:43:19.133Z","response_time":71,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bash","bash-script","command-line-tool","cron-jobs","feedback","minimalist","modulefiles","nohup","reporting-tool","shell-script","testing-tool","unit-testing"],"created_at":"2024-11-25T23:21:25.714Z","updated_at":"2026-05-18T08:06:20.224Z","avatar_url":"https://github.com/michelemartone.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"DABO\n====\n# Did Anything Break Overnight ?\n\nMaintaining good user experience on a system with multiple users\nand administrators requires reproducible procedures, e.g. to:\n - ensure the shell environment is consistent\n - spot erroneous behaviours early on\n - manage user side tickets / incidents\n\nDABO is a humble script to address this.\n\n## A minimalistic, non-invasive helper to user-side\n * testing\n * documentation\n * reporting\nof short shell scripts as test cases.\n\n## DABO fits in\n * automated test runs\n * test-driven development\n\n## DABO is NOT meant to\n * replace per-software test suites or documentation\n * test exhaustively the whole system\n * replace e.g. modulefiles documentation (`module help`)\n * implement heavy automated benchmarks \n * be particularly portable apart from Linux\n * compete with a complete unit testing framework\n\n## DABO can\n * help spoting failing use cases\n * report via email\n * save results in a custom directory\n * produce logs useful as document snippets\n\n## DABO workflow\n * create a directory e.g. `$MYTEST`\n * write test script `$MYTEST/test.sh`, which:\n   - shall succeed (e.g. `exit 0`) on success\n   - shall fail    (e.g. `exit 1`) on failure\n   - shall make NO assumptions on the running directory\n   - runs behalf of the user (so: write safe code)\n * run it dry:    `./dabo.sh -D $MYTEST` # does nothing\n * run it really: `./dabo.sh    $MYTEST`\n   getting PASS / FAIL info for each test\n * run with options, e.g.: `./dabo.sh $OPTS $TEST1 $TEST2 ...`\n * write only small short and stand-alone test scripts\n\n## DABO caution notes\n * DABO performs no chroot or permissions downgrade\n * DABO uses a timeout: if too short, might leave test files around\n * DABO runs under `nice` so not to overload machine\n * DABO copies test each supplied directory, script, and input\n   to a temporary directory under /dev/shm, then destroys it\n * run test scripts of other people under a shared restricted account !!!\n\n## DABO documentation: (from `dabo -h`)\nUsage:\n\n    dabo.sh \u003coption switches\u003e \u003ctest-case\u003e # note: option switches first\n\nA test-case is either a directory containing a test.sh file or a \nprefixed script path like \u003ctest-dir\u003e/test.sh.\nThat test script will be copied to a temporary directory and executed.\nIf it returns zero the test passes, otherwise it fails.\n\nCheck it out:\n\n    mkdir -p echo_test; echo \"echo my echo test;false\" \u003e echo_test/test.sh \n    ./dabo.sh -L echo_test  # fails\n    mkdir -p echo_test; echo \"echo my echo test;true \" \u003e echo_test/test.sh \n    ./dabo.sh -L echo_test  # passes\n\nEnvironment variables:\n\n    DABO_EMAIL       # if set, send report to this email address.\n    DABO_EMAIL_FROM  # if set, send report from this email address.\n    DABO_EMAIL_BCC   # if set, send in Bcc: to this email address.\n    DABO_EMAIL_CC    # if set, send in Cc: to this email address.\n    DABO_SUBJPFX     # if set, email subject prefix\n    DABO_VERBOSITY   # print verbosity: (0) to 4.\n    DABO_TIMEOUT     # test timeout: \u003cnumber\u003e[ms], e.g. 5s, 1m, .. \n    DABO_RESULTS_DIR # where to copy results\n\nOption switches (overriding the environment variables):\n\n    -b $DABO_EMAIL_BCC\n    -c $DABO_EMAIL_CC\n    -e $DABO_EMAIL\n    -f $DABO_EMAIL_FROM\n    -s $DABO_SUBJPFX\n    -v $DABO_VERBOSITY\n    -t $DABO_TIMEOUT\n    -d $DABO_RESULTS_DIR  # -o too\n    -r $DABO_RESULTS_OPTS # any from \"ahnrst.\", default \"nrt\"\n    DABO_RESULTS_OPTS / -r takes a combination of:\n     a : attach tar archives of test cases\n     h : internally uses nohup\n     n : run test under \"nice -n 10\"\n     r : script returns false on any failure\n     s : archive results in shar format\n     t : timestamp in filenames\n     . : ignored (but allows to override defaults)\n\nOption switches meant for interactive use:\n\n    -h :            print help message and exit\n    -L :            view test log with less immediately\n    -P : if passed, view test log with less immediately\n    -F : if failed, view test log with less immediately\n    -D : dry run: checks arguments and exit\n\n## DABO examples\n\n    # intro:\n    git clone https://github.com/michelemartone/dabo.git \u0026\u0026 cd dabo # get the code\n    ./dabo.sh -D true      # dry run: what would be executed ?\n    ./dabo.sh    true      # run trivial passing test, in \"true\" directory\n    ./dabo.sh    false     # run trivial failing test\n    ./dabo.sh    self      # run self test -- shall pass\n    ./dabo.sh              # run all tests -- some will fail\n    ./dabo.sh example_pass # run user example test\n    nl example_pass/test.sh # give a look -- eventually edit\n    #\n    # write your own tests:\n    mkdir -p unfinished_test ; echo \"echo my test\" \u003e unfinished_test/test.sh \n    DABO_VERBOSITY=3 ./dabo.sh unfinished_test  # inspect your running tests\n    mv unfinished_test my_test\n    DABO_EMAIL=my@email ./dabo.sh my_test\n    # \n    # use different collections of tests; like:\n    DABO_TIMEOUT=9s DABO_RESULTS_DIR=$PWD/../demos_results ./dabo.sh demos/*\n    DABO_TIMEOUT=1s DABO_RESULTS_DIR=$PWD/../dabo_results ./dabo.sh envtests/*\n    DABO_TIMEOUT=1m DABO_RESULTS_DIR=$PWD/../dabo_results ./dabo.sh thorough/*\n    #\n    ## crontab -e:\n    # DABO=~/src/dabo/dabo.sh\n    # EMAIL=me@somewhere\n    ## nightly runs (e.g. environment sanity checks):\n    # 00 01 * * *   cd ~/mytests; DABO_EMAIL=$EMAIL                  $DABO demos/*\n    ## weekly runs (e.g. longer ones):\n    # 00 02 * * Sun cd ~/mytests; DABO_EMAIL=$EMAIL DABO_TIMEOUT=5m $DABO thorough/*\n    #\n    ## in your ~/.bashrc:\n    # $ alias dabo=\"dabo.sh -e `pinky -l $USER | grep ^Login |sed 's/^Login.*: *//g;s/ /./g;s/$/\\@lrz.de/'`\"\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmichelemartone%2Fdabo","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmichelemartone%2Fdabo","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmichelemartone%2Fdabo/lists"}