···7575* **Haiku**
7676 * Install: `/boot/system/non-packaged/bin/atfile`
7777 * Config: `$HOME/config/settings/atfile.env`
7878- * `$HOME` is **always** `/home` on Haiku
79788079#### Manually
8180···999810099To compile, run `./atfile.sh build`. The built version will be available at `./bin/atfile-<version>[+git.<hash>].sh`.
101100102102-_(That was easy, huh?)_
101101+### Environment variables
102102+103103+Various environment variables can be exported to control various aspects of the development version. These are as follows:
104104+105105+* `ATFILE_DEVEL_ENABLE_PIPING` <em><int> (default: `0`)</em><br />Allow piping (useful to test installation) _(e.g. `cat ./atfile.sh | bash`)_
106106+* `ATFILE_DEVEL_ENABLE_PUBLISH` <em><int> (default: `0`)</em><br />Publish build to ATProto repository (to allow for updating) as the last step when running `release`. Several requirements must be fulfilled to succeed:
107107+ * `ATFILE_DEVEL_DIST_USERNAME` must be set<br />By default, this is set to `$did` in `atfile.sh` (see **๐๏ธ Building โ Meta**). Ideally, you should not set this variable as updates in the built version will not be fetched from the correct place
108108+ * `ATFILE_DEVEL_DIST_PASSWORD` must be set
109109+ * No tests should return an **Error** (**Warning** is acceptable)
110110+ * Git commit must be <a href="https://git-scm.com/docs/git-tag">tagged</a>
111111+112112+Other `ATFILE_DEVEL_` environment variables are visible in the codebase, but these are computed internally and cannot be set/modified.
113113+114114+### Directives
115115+116116+Various build directives can be set in files to control various aspects of the development version. These are set with `# atfile-devel=` directive at the top of the file, using commas to separate values. These are as follows:
117117+118118+* `ignore-build`<br />Do not include file in the final compiled build
119119+120120+### Meta
121121+122122+Various meta variables can be set to be available in the final compiled build (usually found in `help`). These are found in `atfile.sh` under `# Meta`. These variables are as follows:
123123+124124+* `author` <em><string></em><br />Copyright author
125125+* `did` <em><did></em><br />DID of copyright author. Also used as the source for published builds, unless `ATFILE_DEVEL_DIST_USERNAME` is set (see **๐๏ธ Building โ Environment variables**)
126126+* `repo` <em><uri></em><br />Repository URL of source code
127127+* `version` <em><string></em><br />Version in the format of `<major>.<minor>[.<patch>]`. **Not following this format will cause unintended issues.** Git hashes (`+git.abc1234`) are added automatically during build when a <a href="https://git-scm.com/docs/git-tag">git tag</a> is **not** applied to the current commit
128128+* `year` <em><int></em><br />Copyright year
103129104130## โจ๏ธ Contributing
105131106106-Development mainly takes place on [Tangled](https://tangled.sh/@zio.sh/atfile), with [GitHub](https://github.com/ziodotsh/atfile) acting as a mirror. If possible, please use Tangled for your contributions: since it is powered by ATProto, you can log in using your Bluesky account.
132132+Development takes place on [Tangled (@zio.sh/atfile)](https://tangled.sh/@zio.sh/atfile), with [GitHub (ziodotsh/atfile)](https://github.com/ziodotsh/atfile) acting as a mirror. Use Tangled for your contributions, for both <a href="https://tangled.org/@zio.sh/atfile/issues">Issues</a> and <a href="https://tangled.org/@zio.sh/atfile/pulls">Pulls</a>. As Tangled is powered by ATProto, you already have an account (unsure? Try <a href="https://tangled.org/login">logging in with your Bluesky handle</a>).
107133108108-When submitting Pull Requests, **target the `dev` branch**: `main` is the current stable production version, and PRs will be rejected targeting this branch.
134134+When submitting Pulls, **target the `dev` branch**: `main` is the current stable production version, and Pulls will be rejected targeting this branch.
109135110136## ๐ค Acknowledgements
111137
+6-13
atfile.sh
···1919# it exists) is utilized as normal. Try running `./atfile.sh help`. To turn
2020# debug messages off, set ATFILE_DEBUG to '0'.
2121#
2222-# To produce a single-file build of ATFile, run `./atfile.sh release`: the
2323-# resulting file will be created at './bin/atfile-$version.sh'. Set variables
2424-# below (under '# Meta') to adjust various properties: these will be adjusted
2525-# during build automatically.
2626-#
2727-# Published releases are also done from here. This is done with:
2828-# * Setting ATFILE_DEVEL_PUBLISH to '1'
2929-# * Setting ATFILE_DIST_USERNAME to 'did:web:zio.sh' (default)
3030-# * This account will become the source of updates for this published build
3131-# * Setting ATFILE_DIST_PASSWORD to the above account's password
3232-# * Running `./atfile.sh release`. After build, the resulting file is uploaded
2222+# To produce a single-file build of ATFile, run `./atfile.sh build`: the
2323+# resulting file will be created at './bin/atfile-$version.sh'.
2424+# See README.md โ '๐๏ธ Building' for more details.
3325#
3426# Being a fairly atypical codebase, please don't hesitate to get in touch if
3527# you're wanting to contribute but bewildered by this hot mess. Message
···5850unset ATFILE_DEVEL_DIR
5951unset ATFILE_DEVEL_ENTRY
6052unset ATFILE_DEVEL_SOURCE
5353+[[ -z "$ATFILE_DEVEL_ENABLE_PIPING" ]] && ATFILE_DEVEL_ENABLE_PIPING=0
61546262-if [[ $ATFILE_DEVEL_ALLOW_PIPING != 1 ]]; then
5555+if [[ $ATFILE_DEVEL_ENABLE_PIPING != 1 ]]; then
6356 if [ -p /dev/stdin ] ||\
6457 [[ "$0" == "bash" || $0 == *"/bin/bash" ]]; then
6565- atfile.devel.die "Piping is not supported\n โณ Set ATFILE_DEVEL_ALLOW_PIPING=1 to ignore"
5858+ atfile.devel.die "Piping is disabled\n โณ Set ATFILE_DEVEL_ENABLE_PIPING=1 to ignore"
6659 fi
6760fi
6861
+3-3
src/commands/help.sh
···5353 โน๏ธ Make sure the necessary GPG key has been imported first"
54545555 usage_commands_devel="Commands (Devel)
5656- release
5757- Build (and release) as one file (to ./bin)
5858- โน๏ธ Set ${_envvar_prefix}_DEVEL_PUBLISH=1 to upload release"
5656+ build
5757+ Build (and release, if requested) as one file (to ./bin)
5858+ โน๏ธ Set ${_envvar_prefix}_DEVEL_ENABLE_PUBLISH=1 to upload release"
59596060 usage_commands_lifecycle="Commands (Lifecycle)
6161 update