Commit Graph

583 Commits

Author SHA1 Message Date
a0112b9d3d README: add DOCKER_FINANCE_DEBUG log-levels 2024-09-26 18:38:36 -07:00
01197a2818 client/container: implement debug log-levels
DOCKER_FINANCE_DEBUG will now support the following:

0 = no debug output
1 = `print_debug` (bash/PHP)
2 = level 1 + `set -xv` (bash)
2024-09-26 18:38:36 -07:00
be76a3651b Merge pull request #148 into master
7077e06 client: docker-finance.d: subscript: rewrite (Aaron Fiore)
2024-09-26 18:36:23 -07:00
7077e06d3d client: docker-finance.d: subscript: rewrite
- Refactors and sorts
- Consolidates commands
  * Shortens hledger-{ui,vui,web}
  * Comment out most aliases by default
- Updates to latest impl
- Adds notes and examples
2024-09-26 18:31:55 -07:00
6a54e3bf94 Merge pull request #147 into master
bfdc245 client: src: lib_gen: filter custom Dockerfile's .in files (Aaron Fiore)
a1cea1f client: docker-finance.d: Dockerfiles: add docker-finance version tag (Aaron Fiore)
4a836a7 client: src: lib_gen: filter container config .in files (Aaron Fiore)
f18bd9a client: docker-finance.d: fetch: re-add docker-finance version tag (Aaron Fiore)
ae2c08d client: src: lib_docker: filter docker related .in files (Aaron Fiore)
2024-09-26 18:29:33 -07:00
bfdc2452da client: src: lib_gen: filter custom Dockerfile's .in files
Adds filter to remove noisy license clutter in custom Dockerfile output.

This is needed because of the amount of `edit` used on the file.

The license still applies, regardless.
2024-09-25 21:15:03 -07:00
a1cea1fd1e client: docker-finance.d: Dockerfiles: add docker-finance version tag 2024-09-25 20:54:00 -07:00
4a836a77c4 client: src: lib_gen: filter container config .in files
Adds filters to remove noisy license clutter in configuration output.

This is needed because of the amount of `edit` used on configurations.

The license still applies, regardless.
2024-09-24 19:58:21 -07:00
f18bd9aabb client: docker-finance.d: fetch: re-add docker-finance version tag
This was originally removed because it lacked functional usage, as there
already exists a 'version' key.

However, for consistency across all .in files, adding a version *tag*
(non-YAML) serves to quickly indentify what program this configuration
file actually belongs to.
2024-09-24 19:57:48 -07:00
ae2c08d5df client: src: lib_docker: filter docker related .in files
Creates a clutter-free finalized Dockerfile and docker-compose.yml by
removing all comments and blank lines.
2024-09-24 19:57:44 -07:00
8a1f653127 Merge pull request #146 into master
fd23a93 container: src: lib_edit: add 'subscript' to case (Aaron Fiore)
2024-09-24 18:30:35 -07:00
d3d6847830 Merge pull request #145 into master
dae2572 client: docker-finance.d: hledger: add docker-finance version tag (Aaron Fiore)
4759d10 client: docker-finance.d: hledger: remove comment (Aaron Fiore)
7d4a843 client: docker-finance.d: hledger: remove web args (Aaron Fiore)
5acbbfb container: src: lib_hledger: remove hledger version test (Aaron Fiore)
a9e1ee3 client: docker-finance.d: subscript: remove hledger default args (Aaron Fiore)
da8488e container: src: lib_hledger: fork hledger-web, log print (Aaron Fiore)
8a8395e container: src: lib_hledger: pass hledger-{ui,web} args (Aaron Fiore)
ba29352 client: subscript: remove `ledger` in place of `hledger` (Aaron Fiore)
ea392ec container: remove `ledger` in place of `hledger` (Aaron Fiore)
1101fc8 container: rename `lib_ledger` to `lib_hledger` (Aaron Fiore)
2024-09-24 18:27:37 -07:00
dae2572467 client: docker-finance.d: hledger: add docker-finance version tag 2024-09-24 18:12:47 -07:00
4759d10a59 client: docker-finance.d: hledger: remove comment
Remove an outdated comment; hledger 1.40 is now the minimum provided by
the docker-finance build system.
2024-09-24 18:12:47 -07:00
7d4a843e65 client: docker-finance.d: hledger: remove web args
These args are a baseline requirement within `lib_hledger` impl.
2024-09-24 18:12:47 -07:00
5acbbfb799 container: src: lib_hledger: remove hledger version test
No longer needed because 1.40 is the minimum version provided by the
current build (courtesty of repo 'Dockerfiles/remote/hledger-suite').
2024-09-24 18:12:47 -07:00
a9e1ee39d3 client: docker-finance.d: subscript: remove hledger default args
These args are now passed within container's `lib_hledger` or
docker-finance.d's default generated hledger.conf.
2024-09-24 18:12:47 -07:00
da8488ebb0 container: src: lib_hledger: fork hledger-web, log print
Gives more convenient shell control for end-user.
2024-09-24 18:06:04 -07:00
8a8395e844 container: src: lib_hledger: pass hledger-{ui,web} args
These are currently within the subscript but should be a part of the
baseline command.
2024-09-24 18:06:04 -07:00
fd23a93b0b container: src: lib_edit: add 'subscript' to case
'shell' is the equivalent of 'subscript' (but 'subscript' was missing).
2024-09-24 00:31:01 -07:00
ba293524ef client: subscript: remove ledger in place of hledger
As said before; `lib_ledger` was meant to be a general abstraction to
any underlying CLI ledger.

But, between C++ `ledger` and Ledger Hardware Wallet, this abstraction
has become too confusing and counterproductive.

Since `hledger` will be the underlying implementation for the forseeable
future, all doubt should now be removed.
2024-09-23 18:10:02 -07:00
ea392ec360 container: remove ledger in place of hledger
As said before; `lib_ledger` was meant to be a general abstraction to
any underlying CLI ledger.

But, between C++ `ledger` and Ledger Hardware Wallet, this abstraction
has become too confusing and counterproductive.

Since `hledger` will be the underlying implementation for the forseeable
future, all doubt should now be removed.
2024-09-23 18:09:40 -07:00
1101fc81b4 container: rename lib_ledger to lib_hledger
As said before; `lib_ledger` was meant to be a general abstraction to
any underlying CLI ledger.

But, between C++ `ledger` and Ledger Hardware Wallet, this abstraction
has become too confusing and counterproductive.

Since `hledger` will be the underlying implementation for the forseeable
future, all doubt should now be removed.
2024-09-23 18:09:33 -07:00
77351d54e1 Merge pull request #144 into master
a14dfae README: update to latest `gen` impl (Aaron Fiore)
e6ccd96 client: completion: add `gen` arguments (Aaron Fiore)
f2102c7 client: src: lib_gen: reduce prompt language verbosity (Aaron Fiore)
169034c client: src: lib_gen: refactor/update editor related (Aaron Fiore)
52270ba container: rename $global_conf_shell -> $global_conf_subscript (Aaron Fiore)
0ec42d2 client: rename $global_shell_file -> $global_superscript (Aaron Fiore)
51bf587 client/container: rename 'subprofile' script to 'subscript' (Aaron Fiore)
c8d99e3 client: docker-finance.d: superscript: remove unused tag (Aaron Fiore)
f96dae0 client: src: lib_gen: impl overhaul for new args (Aaron Fiore)
e850938 client: src: lib_gen: add args and args parsing (Aaron Fiore)
9f6ad19 client: src: lib_gen: move hledger conf to subprofile gen (Aaron Fiore)
c3cf815 client: src: refactor system checks (Aaron Fiore)
d8222c6 client: src: refactor environment/gen handler (Aaron Fiore)
2024-09-23 17:49:35 -07:00
a14dfaedde README: update to latest gen impl 2024-09-23 17:31:12 -07:00
e6ccd9607c client: completion: add gen arguments 2024-09-23 17:31:12 -07:00
f2102c7b90 client: src: lib_gen: reduce prompt language verbosity 2024-09-23 17:31:11 -07:00
169034cbe2 client: src: lib_gen: refactor/update editor related
- Creates a reusable editor function
- Skipping confirmations will also skip opening up the editor
  * Allows for complete generation without intentional interruption
2024-09-23 17:31:11 -07:00
52270ba0b3 container: rename $global_conf_shell -> $global_conf_subscript
Provides clarity, avoids confusion.
2024-09-23 17:31:11 -07:00
0ec42d2420 client: rename $global_shell_file -> $global_superscript
Provides clarity, avoids confusion.
2024-09-23 17:31:11 -07:00
51bf587ceb client/container: rename 'subprofile' script to 'subscript'
- Provides clarity, avoids confusion (subprofile.bash -> subscript.bash)

- Changes filename in superscript source
  * End-user must update with client command `edit type=superscript`

- Changes filename in flow subprofile's docker-finance.d
  * Pre-existing subprofiles must manually rename their subscript file
2024-09-23 17:31:11 -07:00
c8d99e3f12 client: docker-finance.d: superscript: remove unused tag
Impl now appends, regardless of tag.
2024-09-23 17:31:11 -07:00
f96dae0210 client: src: lib_gen: impl overhaul for new args
- Rewrite to support new arguments
  * Related design changes and refactoring
  * Remove prompt for testing (use `dev=on` instead)
- Factor out superscript gen from subscript append
- Related print formatting changes
- Add more internal checks
2024-09-23 17:31:11 -07:00
e8509384d2 client: src: lib_gen: add args and args parsing
- Allows for a dynamic `gen` experience
  * All configs/accounts can now be (re)generated on-the-fly
    - Individually, by section, or all at once
  * Adds prompt confirmation option
  * Adds developer profile option
2024-09-23 17:31:11 -07:00
9f6ad19112 client: src: lib_gen: move hledger conf to subprofile gen
Subprofile's hledger conf should be within subprofile generation.
2024-09-22 19:35:22 -07:00
c3cf81572b client: src: refactor system checks
- UID and dependency checks are done in internal `lib_docker`/`lib_env`
- Moves `sed` check to appropriate `lib_env`
2024-09-22 19:35:22 -07:00
d8222c60fb client: src: refactor environment/gen handler
- Moves environment handling from `lib_gen` to `lib_env`
- Related refactoring
2024-09-22 19:35:22 -07:00
b2fcb02225 Merge pull request #143 into master
0b2c76a container: finance: add dependency checks for modules (Aaron Fiore)
6d0a38f client: manifest: update to latest impl (Aaron Fiore)
e7d749b client: docker-finance.d: Dockerfiles: cleanup, clarify (Aaron Fiore)
dc4990a client: docker: complete build overhaul, optimize (Aaron Fiore)
2024-09-22 19:31:38 -07:00
0b2c76a813 container: finance: add dependency checks for modules
Since modules are included upon build type, if a build doesn't support
a feature then that feature's dependencies will not be available.

This commit will give notice of those missing dependencies.
2024-09-17 20:06:34 -07:00
6d0a38f6b5 client: manifest: update to latest impl 2024-09-17 20:06:33 -07:00
e7d749ba22 client: docker-finance.d: Dockerfiles: cleanup, clarify 2024-09-17 20:06:33 -07:00
dc4990ab90 client: docker: complete build overhaul, optimize
This commit brings a complete overhaul of the build system:

- Creates a separation of concerns for 'local' and 'remote' building
  * 'local' is built locally via the docker-finance `build` command
  * 'remote' is built *outside* of the docker-finance `build` command
    (pushed to a remote registry and then pulled by the 'local' build)
  * Related refactoring
    - Dockerfiles
    - `lib_gen`

- Adds remote image 'hledger-suite'
  * Provides the latest versions of all `hledger` related binaries
  * No longer relies on package maintainers / out-dated packages

- Adds remote image 'docker-finance'
  * Provides base image for 'finance' and 'dev-tools' images
    - tags 'archlinux' | 'ubuntu' | 'dev-tools'

- Removes previous `hledger` related build modules
  * Removes building any `hledger` related binaries locally

- Removes 'experimental' build
  * End-user can use local custom Dockerfile and/or custom tag instead

- Updates the 'default' | 'slim' | 'tiny' | 'micro' build types
  * Refactors build type requirements into separate build modules
    - Adds 'fetch' module
    - Adds 'track' module
    - Adds 'user' module
      * creates container user *after* base and all other modules
      * allows for quick re-building across multiple local users
    - Updates 'root' module
  * `lib_docker`
    - Updates usage help
    - Adds build modules per build type

- Huge optimizations
  * Vastly improves build times
    - ~60% faster w/ a fresh build
    - ~60%-90% faster rebuild (depending on image type)
  * Vastly improves image sizes
    - e.g., 'default' Arch Linux image size is ~50% smaller
2024-09-17 20:06:33 -07:00
9feb05be2d Merge pull request #142 into master
7c46719 container: finance: lib_fetch: fix Tor plugin (proxychains) check (Aaron Fiore)
2024-09-16 22:09:04 -07:00
7c46719ab1 container: finance: lib_fetch: fix Tor plugin (proxychains) check
This ensures that curl will only be executed if the Tor plugin
(proxychains) argument is enabled.
2024-09-16 21:10:49 -07:00
c8177a0736 Merge pull request #141 into master
f200cfb README: fix TradFi anchor tag (Aaron Fiore)
5d21061 README: add support for NonFi (Aaron Fiore)
2024-09-13 16:59:16 -07:00
f200cfba8f README: fix TradFi anchor tag 2024-09-11 21:47:11 -07:00
5d2106183b README: add support for NonFi 2024-09-11 21:46:46 -07:00
ae061f9e0b Merge pull request #140 into master
a16922f container: hledger-flow: add Vultr support (Aaron Fiore)
2024-09-11 21:27:43 -07:00
a16922f87a container: hledger-flow: add Vultr support
This addition is treading a fine line between finance and other
accounting, as Vultr cloud service is related to DevOps and is also not
a financial entity. However, financial information is provided; so this
addition is useful.

With this commit, a precedent is set for other cloud services to be
added to the repository (services that provide CSV financial accounting
data) and I believe that they could (should) be added as needed.

NOTE: there are several upstream CSV issues:

  - Only expenses are given
    * Transfers must be added manually (manual import or custom rules)

  - Sales tax is not included
    * Sales tax expenses must be added manually
2024-09-11 21:25:51 -07:00
a93dc4adfa Merge pull request #139 into master
afa2e36 container: finance: completion: add `hledger` commands (Aaron Fiore)
2024-09-11 21:19:59 -07:00