DavHau
10bbe80f13
refactor: tlib
-> dlib.translators
2022-02-23 19:25:52 +07:00
DavHau
b78958849d
remove dependency nix-parsec
2022-02-23 19:12:33 +07:00
DavHau
ae3172315e
new yarn parser (supports yarn2)
2022-02-23 19:06:08 +07:00
DavHau
6a46a26700
extend translator templates with projectName
2022-02-23 17:40:19 +07:00
DavHau
485eb0be73
feature: allow omitting pname
on makeFlakeOutputs
2022-02-23 17:35:01 +07:00
DavHau
7e78d8b37b
move some translator funcs to system independent lib
2022-02-23 16:51:47 +07:00
DavHau
8f2fd2afed
rename: compatiblePaths -> compatible
2022-02-23 15:29:53 +07:00
DavHau
02eb4a1cf4
refactor: source instead of inputDirectories/Files
2022-02-23 15:26:34 +07:00
DavHau
b4fef5baf0
make some translator functions system independent
...
- introduce `dlib` - system independent lib
- refactor all translators, to make functions extraArgs and conpatiblePaths system independent
2022-02-23 14:59:42 +07:00
DavHau
3e19b05b9a
fix: sourceOverrides not applied to path sources
2022-02-23 12:15:27 +07:00
DavHau
59754b406d
nodejs: fix 2 bugs in granular builder
...
1. package.json dependencies can be a list
2. bin symlinking for namespace packages
2022-02-23 12:13:50 +07:00
DavHau
d19ec4932b
fix --no-default-nix description
2022-02-23 12:11:25 +07:00
DavHau
195d0a7e03
fix bug when translatorArgs contained integer
2022-02-22 21:00:40 +07:00
DavHau
a1449936ff
fix projectRoot config missing
2022-02-22 20:24:53 +07:00
DavHau
767db79095
raname: riseAndShine -> make[Flake]Outputs
2022-02-22 20:21:33 +07:00
DavHau
d8300cb909
Always build from dream-lock.json if exists
...
- add an invalidationHash to dream-lock.json
- always evaluate dream-lock.json if exists
- warn user if dream-lock.json doesn't exist
2022-02-22 18:23:49 +07:00
DavHau
ba967fcbe0
remove (most) interactivity of CLI
2022-02-22 15:10:01 +07:00
DavHau
2772c26105
integrate impure translation with flakes
...
Now if dream2nix is used via flakes and impure translation is required, the user will be isntructed to `nix run ...` something to generate the missing dream-lock.
2022-02-22 15:04:16 +07:00
Yusuf Bera Ertan
129134fcd3
fix(rust): don't vendor path deps, handle git dep configs more correctly, handle cyclic deps correctly
2022-02-20 12:16:09 +03:00
Yusuf Bera Ertan
947fb621a8
fix(rust): write cargo checksum for path dependencies
2022-02-10 20:30:26 +03:00
DavHau
2167b7e993
fix bug in rust packages structure
2022-02-10 12:47:58 +07:00
DavHau
04901e48d2
update dream-lock.example for rust subsystem
2022-02-10 11:44:50 +07:00
DavHau
4f35c7b633
rust translator/builder to use dream-lock packages
2022-02-10 11:43:14 +07:00
DavHau
f634038bbf
WIP - adapt code to dream lock changes
2022-02-10 11:43:14 +07:00
DavHau
28c29947cd
dream-lock structure changes
...
remove fields:
- translator
- translatedBy
- mainPackageName
- mainPackageVersion
add fields:
- defaultPackage
- packages
2022-02-10 11:43:14 +07:00
DavHau
ea3d1a2ac1
simplify example flake.nix
...
fixes a bug where a source tree input was interpreted as a laoded dream-lock
2022-02-09 15:13:49 +07:00
DavHau
817f4d3ba0
package-json transl.: add arg 'npmArgs'
2022-02-04 13:40:56 +07:00
Yusuf Bera Ertan
405e63e941
feat: throw an error in getSourceSpec if the requested dep doesnt exist
2022-01-16 13:00:53 +03:00
Yusuf Bera Ertan
2477a55fbb
fix(rust): put relative paths instead of store paths in lockfile for path deps
2022-01-16 12:56:54 +03:00
Yusuf Bera Ertan
e8c4baf602
feat(rust): use script instead of nix code to find crate paths
2022-01-16 12:56:54 +03:00
Yusuf Bera Ertan
3c6af2acbf
feat(rust): remove git deps from subsystem attrs, use getSourceSpec instead
2022-01-16 12:56:54 +03:00
Yusuf Bera Ertan
c9ea0f7c13
feat: add getSourceSpec
2022-01-16 12:56:54 +03:00
Yusuf Bera Ertan
1d8fc17b93
feat(rust): extend the dream.lock.example.json for the subsystem
2022-01-16 12:56:54 +03:00
Yusuf Bera Ertan
5d18abcdab
fix(rust): write cargo-checksum for vendored git dependencies
...
fix(rust): copy sources instead of symlinking so we can write cargo checksum
feat(rust): add trace for is git
feat(rust): add trace for is git
feat(rust): add trace for git deps
feat(rust): add trace for git deps
fix(rust): use findFirst not findSingle for finding git dep
fix(rust): remove is git trace
refactor(rust): remove unused code
2022-01-16 12:56:54 +03:00
Yusuf Bera Ertan
901f8a4fc8
fix(rust): pass git dependency parsed information to builders, generate cargo config for git dependencies
...
fix(rust): fix infinite recursion caused by same name
fix(rust): split gitDeps, generate vendor entries properly
fix(rust): fix infinite recursion in builder
fix(rust): apply git source type to generated vendor entries after applying replace-with
fix(rust): don't overwrite cargo config with generated entries
2022-01-16 12:56:54 +03:00
Yusuf Bera Ertan
e5e88a03b5
feat(rust): workaround git dependencies that are in a workspace by locating the crate source more accurately
...
fix(rust): copy over findCratePath to builder
fix(rust): correct getAllFiles usage
2022-01-16 12:56:54 +03:00
Yusuf Bera Ertan
f380a81016
fix(rust): dont use src.name
...
feat(rust): add trace to builder
2022-01-16 12:56:54 +03:00
Max
2132262d5c
yarn-lock: allow empty quoted strings
2022-01-13 19:34:36 +01:00
Tom Bereknyei
d2143bb96d
Parse unquoted strings in yarn.lock
...
Sometimes there will be unquoted strings (eg: latest) in dependecy
positions. They are resolved elsewhere but results in a parse error.
2022-01-10 11:03:52 -05:00
DavHau
e69cb52ab0
nodejs builder+translator improvements
2021-12-22 17:31:37 +01:00
DavHau
792deb6a6b
feature: CLI: add --sub-dirs flag to enable recursive package transaltion
2021-12-22 17:28:34 +01:00
DavHau
72e73fa255
bugfix: unable to parse tsconfig with comments
2021-12-19 17:06:44 +01:00
DavHau
013dc86524
improve electron support
2021-12-19 14:39:33 +01:00
DavHau
a08f5eb25a
merge dev
2021-12-11 11:12:52 +07:00
DavHau
8934508e66
refactor simpleTranslate
2021-12-11 09:13:26 +07:00
DavHau
6a96f26e14
nodejs builder: support electron apps
2021-12-11 09:07:14 +07:00
DavHau
dafda69911
add.py: imporve handling+naming of subpackages
2021-12-11 09:05:59 +07:00
DavHau
87b6959039
fix updating packages + add test
2021-12-09 15:47:08 +07:00
DavHau
728677b654
nodejs package-json: improve + add arguments
2021-12-09 14:46:12 +07:00
DavHau
ed08f9e24c
fix fetchers: npm, pypi
2021-12-09 12:55:32 +07:00
DavHau
d608742406
fix: yarn-lock translator
2021-12-08 23:29:09 +07:00
DavHau
1358e1a303
always use internal overrides
2021-12-08 23:18:21 +07:00
DavHau
12c9f565aa
nodejs: use package name set via CLI
2021-12-08 23:18:21 +07:00
DavHau
c441eabbb8
make nodejs configurable
2021-12-08 23:18:21 +07:00
Yusuf Bera Ertan
0e236db189
fix(build-rust-package): use produceDerivation to apply overrides to the resulting package(s)
2021-12-03 07:40:55 +03:00
DavHau
d3a279875e
feature: support multiple packages per source
2021-12-02 14:15:40 +07:00
DavHau
133b2d0093
fix shortcuts + pname, version handling
2021-11-30 12:36:49 +07:00
Yusuf Bera Ertan
0903f5ea43
feat: pass version and pname to fetchers ( #60 )
...
* feat: pass version and pname to fetchers, adjust schema for new behaviour
* fix: name -> pname
* refactor: move override warning to simpleTranslate, flatten dependencyInfo
2021-11-30 12:20:27 +07:00
DavHau
c5126b2053
feature: installMethod copy
2021-11-29 18:44:30 +07:00
Yusuf Bera Ertan
bfcd5b6f35
feat: cargo lock translator, rust builder ( #59 )
2021-11-29 18:34:53 +07:00
DavHau
fb42313192
bugfix add.py
2021-11-24 09:44:43 +07:00
DavHau
b8dc44d0f2
feature: translate subdir of source via ?dir=foo
2021-11-24 08:50:05 +07:00
DavHau
9d2d385273
test nix funcs with pytest via nix_ffi.py
2021-11-20 11:34:04 +07:00
DavHau
5ad6855226
fix: aggregated fetching
2021-11-18 12:09:14 +07:00
DavHau
553d29724f
bugfixes: fixes #54 , fixes #55
...
- add package vie http URL
- create default.nix for debugging
- package-lock parse `npm:` reference
2021-11-18 11:33:24 +07:00
DavHau
4cf80a1460
add test for aggregated fetching: github source
2021-11-17 17:40:09 +07:00
DavHau
e99487cee9
rename sourcesCombinedHash -> sourcesAggregatedHash
2021-11-17 17:12:02 +07:00
DavHau
97e2fef121
fix & improve aggregated source fetching
2021-11-17 17:09:25 +07:00
DavHau
87157ecc8b
fix NIX_PATH impurity in writePureShellScript
2021-11-17 12:18:22 +07:00
DavHau
b4b7435ca3
Merge branch 'dev' into go
2021-11-17 11:28:22 +07:00
DavHau
3b5b9096e1
hercules ci + improvements
...
- yarn-lock: add nodejs version argument
- add impure tests
- add ci.nix for hercules
2021-11-17 11:23:31 +07:00
Akshat Agarwal
ff9e30b242
add go support using gomod2nix
...
Co-authored-by: DavHau <hsngrmpf+github@gmail.com>
2021-11-16 23:28:05 +05:30
DavHau
ec63d19cf5
add.py: refactor spaghetti into functions
2021-11-16 17:02:22 +07:00
DavHau
1c31d53605
fix: add packages via git URL + params; fetch submodules
2021-11-16 08:50:00 +07:00
DavHau
079ec025dc
nodejs builder: fix executing $buildScript
2021-11-15 18:10:22 +07:00
DavHau
f1e34e0e89
builder API; move override logic into produceDerivation
...
This should simplify writing builders
2021-11-13 17:41:48 +07:00
DavHau
163db67245
package-lock: handle resolved=false
2021-11-12 21:52:57 +07:00
DavHau
3ec6baf2c4
support parsing github:...
URLs
2021-11-12 21:52:32 +07:00
DavHau
def2b8b499
package-lock translator: deal with more weirdnes
2021-11-12 14:34:48 +07:00
DavHau
6d2a9fd95e
nodejs buider: fix crash on empty string bin
field
2021-11-11 19:08:25 +07:00
DavHau
48af5f0ec1
nodejs builder: just exclude cyclic deps
2021-11-10 14:05:51 +07:00
DavHau
6097051a5f
automatically add new packages to git
2021-11-10 13:11:33 +07:00
DavHau
9302d24fc3
add name argument to package-lock translator
2021-11-10 13:11:21 +07:00
DavHau
baa442739f
add template and docs for contributing builder
2021-11-08 11:47:15 +07:00
DavHau
791bb7638f
pure translator template based on simpleTranslate
2021-11-08 09:44:27 +07:00
DavHau
8f743b24d4
yarn-lock: fix parsing github URL with revision
2021-11-07 23:59:46 +07:00
DavHau
9fc0623a48
nodejs builder: improve phases
2021-11-07 15:18:28 +07:00
DavHau
9ff7a0ab58
CLI improvements
...
- rename command package -> add
- improve handling of dream2nix config
- improve purity of cli execution
- automatically find git repo root
- improve package update cli
2021-11-07 15:18:28 +07:00
DavHau
60d89f776f
improve flake interfaces and apps
...
- improve exposing apps for other flakes
- configure overridesDirs via config
2021-11-07 15:18:28 +07:00
DavHau
39db511926
improve override system
...
- add utils.satisfiesSemver (from poetry2nix)
- nix-parsec add LICENSE from https://github.com/nprindle/nix-parsec/issues/5
- remove builtin overrides (moved to dreampkgs)
2021-11-07 15:18:28 +07:00
DavHau
bccf3b25c7
multiple override dirs, nodejs improvements
...
- nodejs builder: symlink sub dependencies
- allow multiple directories with overrides
- rename app: cli -> dream2nix
2021-11-07 15:18:28 +07:00
DavHau
62317e6501
fix: inject
2021-11-07 15:18:28 +07:00
DavHau
74a2a2351e
ask to create default.nix by default
2021-11-07 15:18:14 +07:00
DavHau
a936cf44a5
rename dream.lock -> dream-lock.json
2021-11-04 15:48:40 +07:00
DavHau
a1d0ed99a8
restructure / rename dream-lock attributes
2021-11-04 15:36:12 +07:00
DavHau
c2e9d3adf4
yarn: remove noOptional + improve UI
2021-11-04 15:02:44 +07:00
DavHau
b1cb420434
fixes for yarn translator and node builder
2021-11-03 10:46:02 +07:00
DavHau
aa81800846
fixes and improvements for nodejs
...
- add system specific dream2nix to flake outputs
- add more overrides
- overrides allow regex as key
2021-11-02 15:13:34 +07:00
DavHau
f1662dabe5
cleanup package.json translator
2021-11-01 15:16:39 +07:00
DavHau
4ef9af0f73
add translator.package.json
...
- update default.nix template
- add npm to dream lock schema
- handle empty depedency graph in readDreamLock
2021-11-01 14:42:02 +07:00