@@ -32,11 +32,11 @@ lbfTypescriptOpts@{
3232 # # [flake-lang.nix](https://github.com/mlabs-haskell/flake-lang.nix) as well.
3333 # npmExtraDevDependencies ? [ ]
3434, configs ? [ ]
35- , # Name of the package and also the name of the Cabal package.
35+ , # Name of the package
3636 # Examples: name = "lbf-myproject"
3737 name
38- , # Version of the package and also the version of the Cabal package.
39- # Examples: version = "0. 1.0.0"
38+ , # Version of the package
39+ # Examples: version = "1.0.0"
4040 version ? "1.0.0"
4141
4242, # `tsconfig.json` for TypeScript. Note that the typechecking options do
206206 buildPhase =
207207 ''
208208 export HOME=$(mktemp -d)
209- ln -s ${ lbfBuilt } autogen;
210- ln -s ${ lbfBuilt . workdir } .work-dir;
211- ln -s ${ lbfBuilt . buildjson } build.json;
209+ ln -s ${ pkgs . lib . escapeShellArg lbfBuilt } autogen;
210+ ln -s ${ pkgs . lib . escapeShellArg lbfBuilt . workdir } .work-dir;
211+ ln -s ${ pkgs . lib . escapeShellArg lbfBuilt . buildjson } build.json;
212212
213213 ###########################
214214 # Creating the packages json files
229229 | xargs -I % sh -c 'echo "$0" | sed -E "s#^autogen/(.*)\.mts\$#\1.mjs#"' % \
230230 | xargs -I % sh -c 'echo "| .\"exports\".\"./$0\"=\"./dist/$0\"" >> jq_filter.jq' %
231231
232- cat ${ packageJsonTemplate } | jq -f jq_filter.jq > package.json
233- cat ${ packageJsonLockTemplate } > package-lock.json
234- cat ${ tsConfigJson } > tsconfig.json
232+ cat ${ pkgs . lib . escapeShellArg packageJsonTemplate } | jq -f jq_filter.jq > package.json
233+ cat ${ pkgs . lib . escapeShellArg packageJsonLockTemplate } > package-lock.json
234+ cat ${ pkgs . lib . escapeShellArg tsConfigJson } > tsconfig.json
235235
236236 '' ;
237237
269269 --loglevel verbose \
270270 --offline \
271271 --package-lock-only \
272- --save ./${ tsSelf . npmExtraDependenciesFolder } /*
272+ --save ./${ pkgs . lib . escapeShellArg tsSelf . npmExtraDependenciesFolder } /*
273273 '' ;
274274 }
275275 ) ;
0 commit comments