From 338db72033d06f052b91c291c77bfbf687890f23 Mon Sep 17 00:00:00 2001 From: Ralph Amissah Date: Sun, 10 Apr 2022 13:49:46 -0400 Subject: project config minor, also .gitignore --- org/sisu_build.org | 169 +++++++++++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 159 insertions(+), 10 deletions(-) (limited to 'org') diff --git a/org/sisu_build.org b/org/sisu_build.org index c9d05937..b0f32dfd 100644 --- a/org/sisu_build.org +++ b/org/sisu_build.org @@ -2531,8 +2531,12 @@ end #+HEADER: :tangle ../.envrc #+BEGIN_SRC sh NIX_ENFORCE_PURITY=0 -if [ -e .envrc-local ]; then # source an additional user-specific .envrc in ./.envrc-local - source .envrc-local +if ! has nix_direnv_version || ! nix_direnv_version 1.4.0; then +# https://github.com/nix-community/nix-direnv + source_url "https://raw.githubusercontent.com/nix-community/nix-direnv/1.4.0/direnvrc" "sha256-4XfVDjv75eHMWN4G725VW7BoOV4Vl3vAabK4YXIfPyE=" +fi +if [ -e .env/local ]; then + source_env_if_exists .env/local || source .env/local fi #+END_SRC @@ -2562,22 +2566,56 @@ export RUBYLIB+=`pwd`/lib #+HEADER: :tangle-mode (identity #o755) #+BEGIN_SRC nix { pkgs ? import {} }: -pkgs.mkShell { - buildInputs = [( - with pkgs; [ - <> - <> - <> - ] - )]; +with pkgs; +mkShell { + buildInputs = [ + <> + <> + <> + <> + ]; shellHook = '' if [[ -e ".envrc" ]]; then source .envrc fi + eval "$(starship init bash)" ''; } #+END_SRC +#+BEGIN_SRC nix +#!/usr/bin/env -S nix-shell --pure +{ pkgs ? import {} }: +with pkgs; +mkShell { + buildInputs = [ + ruby_3_1 + rubyPackages_3_1.rake + rubyPackages_3_1.sqlite3 + rubyPackages_3_1.thor + sqlite + unzip + xz + zip + openssl + #texlive-combined-full + nixFlakes + validatePkgConfig + jq + git + ### candy + starship + ]; + shellHook = '' + if [[ -e ".envrc" ]]; then + source .envrc + fi + eval "$(starship init bash)" + ''; +} +#+END_SRC + + #+HEADER: :NO-tangle ../shell.nix #+BEGIN_SRC nix { pkgs ? import {} }: @@ -2718,6 +2756,11 @@ jq git #+END_SRC +#+NAME: packages_extra +#+BEGIN_SRC nix +starship +#+END_SRC + * descriptions ** README @@ -5987,6 +6030,112 @@ Configure substitution in _sisu/sisu_document_make data/sisu/conf/editor-syntax-etc/emacs/ data/sisu/conf/editor-syntax-etc/emacs/sisu-mode.el +** git +*** gitignore + +#+HEADER: :tangle ../.gitignore +#+BEGIN_SRC sh +# git ls-files --others --exclude-from=.git/info/exclude +* +!README +!COPYRIGHT +!CHANGELOG +!CHANGELOGS/ +!CHANGELOGS/CHANGELOG +!CHANGELOGS/CHANGELOG_v* +!makefile +!Rakefile +!Rantfile +!qi +!setup/ +!setup/* +!version +!version.txt +!conf/ +!conf/** +!*.json +!*.org +!*.rb +!*.txt +!*.yml +!*.nix +!nix/ +!nix/** +!org/ +!bin +!bin/sisu +!bin/sisu-* +!bin/sisugem +!lib +!lib/** +!man +!man/** +!data +!data/doc +!data/doc/** +!data/sisu +!data/sisu/** +!*.sst +!*.ssm +!**/*.sst +!**/*.ssm +!debian/ +!debian/changelog +!debian/compat +!debian/control +!debian/copyright +!debian/gbp.conf +!debian/sisu*.manpages +!debian/sisu*.install +!debian/manpages/ +!debian/manpages/sisu*.7 +!debian/rules +!debian/sisu\.* +!debian/source/ +!debian/source/format +!debian/watch +*~ +*_ +\#* +*.\#* +*.tmp +*_tmp +*.gem +*.gemspec +!sisu.gemspec +*_.rb +*.rb_ +0???-*.patch +*.gz +*.xz +*_ +.* +!.gitignore +!.envrc +#+END_SRC + +##+HEADER: :tangle ../.gitignore +#+BEGIN_SRC sh +# git ls-files --others --exclude-from=.git/info/exclude +,*~ +,*_ +\#* +,*.\#* +,*.tmp +,*_tmp +.* +,*.gem +,*.gemspec +!.gitignore +!.envrc +,*_.rb +,*.rb_ +.pc +0???-*.patch +,*.gz +,*.xz +#+END_SRC + *** todo sisu_todo.org -- cgit v1.2.3