Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rewrite bash wrapper in Amber #16

Merged
merged 23 commits into from
Feb 26, 2025
Merged

Rewrite bash wrapper in Amber #16

merged 23 commits into from
Feb 26, 2025

Conversation

Thesola10
Copy link
Collaborator

@Thesola10 Thesola10 commented Feb 7, 2025

Right now, the Nix wrapper script (nix-wrapped.sh.in) is a monolithic, 600 lines of handwritten Bash. This in turn is an issue when it comes to maintainability of a pivotal part of Nixie.

Rewriting everything in the Amber compiled language brings with it several improvements:

  • Improved handling of arrays/lists
  • Standard library for downloading files
  • Splitting the script into importable components
  • Proper error handling and separation of "failable" components
  • NEW: Adding individual entry points to components like builders for faster development and testing

This PR also overhauls the Python build system by moving the Python module at the root of the repository, and switching to Hatch from Setuptools as a build backend.

@Thesola10 Thesola10 added the type: enhancement New feature or request label Feb 7, 2025
@Thesola10 Thesola10 force-pushed the amber-ng branch 2 times, most recently from 76a296f to cae95a7 Compare February 10, 2025 12:21
@Thesola10
Copy link
Collaborator Author

Due to it being based on Amber 0.4.0, this version currently introduces a hard dependency to sed and bc.

@Thesola10 Thesola10 force-pushed the amber-ng branch 2 times, most recently from ab29f60 to 8538813 Compare February 24, 2025 09:54
@Thesola10 Thesola10 marked this pull request as ready for review February 24, 2025 09:54
@Thesola10 Thesola10 force-pushed the amber-ng branch 2 times, most recently from a6687e0 to 45b1c8c Compare February 24, 2025 10:55
Also removes the need for the "ensure used" marker
@Thesola10 Thesola10 force-pushed the amber-ng branch 2 times, most recently from fcb930d to 6b26d37 Compare February 24, 2025 12:09
@Thesola10 Thesola10 force-pushed the amber-ng branch 3 times, most recently from f4c9aff to cd7129d Compare February 24, 2025 17:14
@Thesola10 Thesola10 force-pushed the amber-ng branch 3 times, most recently from 3cfbf23 to c612372 Compare February 25, 2025 10:34
@Thesola10 Thesola10 merged commit 4f25d70 into master Feb 26, 2025
2 checks passed
@Thesola10 Thesola10 deleted the amber-ng branch February 26, 2025 23:33
@Thesola10 Thesola10 mentioned this pull request Feb 27, 2025
4 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant