-
Notifications
You must be signed in to change notification settings - Fork 19
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
Add Nix flake, devshell, package, and wrapper script #18
Open
spikespaz
wants to merge
18
commits into
R-O-C-K-E-T:main
Choose a base branch
from
spikespaz-contrib:nix-flake
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I have added a Nix flake to this repository that includes a package description, and a development shell, as well as some of the standard tricks for Nix users.
I have also added a wrapper (
cli.nix
) so that if a user wants this installed on their system, they can install the packagefactorio-sat-cli
and get one command,factorio-sat
, instead of many scripts on theirPATH
.There is a significant change to the Python codebase, it fetches assets from
$XDG_DATA_HOME
. I made those changes a while ago now; if you want me to rebase to make a change, I can.nix run github:spikespaz-contrib/factorio-sat
will run the wrapper, and show you all of the commands. Then, pass arguments after--
, such asnix run github:spikespaz-contrib/factorio-sat -- belt_balancer
, which will show the help for thebelt_balancer
script.nix build github:spikespaz-contrib/factorio-sat
will fetch dependencies and install the scripts to./result/bin
. This is not the CLI wrapper.nix build 'github:spikespaz-contrib/factorio-sat#factorio-sat-cli'
will build the CLI wrapper, which lives at./result/bin/factorio-sat
. There are no other scripts or dependencies inbin
, the CLI script is self-contained.nix develop github:spikespaz-contrib/factorio-sat
will put you in a shell with all dependencies and the interpreter. This shell is dual-purpose: it provides the development environment yes, but users can also run this command to get the scripts temporarily on theirPATH
.nix develop
(in locally cloned repository) will open the development shell, same as before. Again, this can be used to work on Factorio-SAT itself, or to just run the scripts fromPATH
.