#This may actually be a terrible idea,
1 messages ยท Page 1 of 1 (latest)
I fully understand that hiding the url may be actual bad UX and having a long url might actually be better ๐
coming imminently:
dagger install LONG; dagger call -m SHORT
We're going to piggyback on dependencies field already in dagger.json, and expose it to the CLI as well
first step towards that is a PR by @woven stratus that make dagger init initialize a codeless module- basically just a dagger.json. So you can start installing and calling functions from other modules before writing functions of your own. When you're ready to dev your own functions: dagger develop --sdk
in addition to convenience it also guarantees you're calling the same digest you installed
The basic support for short names actually made it in v0.9.8, e.g.
sipsma@dagger_dev:~/short$ dagger mod init
WARNING: no LICENSE file found; generating one for you, feel free to change or remove license="Apache-2.0"
โข Engine: 96ebbc1e0b32 (version v0.9.8)
โง 2.05s โ 21 โ
5
sipsma@dagger_dev:~/short$ dagger mod install github.com/shykes/daggerverse/hello --name foo
โข Engine: 96ebbc1e0b32 (version v0.9.8)
โง 5.84s โ 97 โ
6
sipsma@dagger_dev:~/short$ dagger call -m foo hello
โ dagger call hello [0.67s]
โ Hello, world!
โข Engine: 96ebbc1e0b32 (version v0.9.8)
โง 2.94s โ 63 โ
7
--name on install is optional, defaults to name of the module
there you go @sterile dove ๐
will make more sense in combination with lightweight init
Nice, thanks yall
Note @sterile dove , defaulting to your home directory if no dagger.json is detected, is planned but not supported yet. We still need to bikeshed little things, like "does it go in ~/dagger.json, or ~/.dagger/dagger.json?", plus we're tight on implementing more urgent things, so it's in the queue
The standard workflow going forward, will be to dagger init at the root of your git repo