-
Notifications
You must be signed in to change notification settings - Fork 9
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
how can i use
a module with setup-nu
?
#40
Comments
in the end i was able to work around the problem by
👍 |
Thanks for the feed back, I will try to fix it, but I'm not sure is there a good way |
😊 not urgent at all 😌 ideas
cheers 😋 👋 |
I have tried many ways here: 24412a4, however, they all failed. |
Maybe I can give it a try after nu v0.79 released due to nushell/nushell#8870 |
The only way works I found is here: https://github.com/hustcer/setup-nu/blob/develop/.github/workflows/module-test.yaml - name: Cp Your Modules to NU_LIB_DIRS
run: |
let LIB_DIR = ($nu.config-path | path dirname | path join 'scripts')
mkdir $LIB_DIR
cp nu/common.nu $LIB_DIR
print 'Available Nu Modules:'
print (ls ($env.NU_LIB_DIRS | get 0))
- name: Use Your Nu Modules In the Following Steps
run: |
use common.nu [get-env]
print (get-env 'ABC-XYZ' 'DEFAULT-ABC-XYZ') Running result: https://github.com/hustcer/setup-nu/actions/runs/4742880511/jobs/8421700478 |
@hustcer
oooh i see what you're doing here and that it works.
well if you find something and want someone to test 😏 |
Update: https://github.com/hustcer/setup-nu#use-modules It works for |
noice, will see if i encounter this again 😌 |
I came to request |
@texastoland That's a good idea. PRs are welcomed. |
I looked at the code but it wasn't obvious where to start. I'm motivated to get it working for CI testing on nu_scripts though. Better in a channel or DM if I need help? |
You can contact me by discord, username hustcer |
Related to the original issue I tried all the following unsuccessfully:
But |
hellord @hustcer 👋 😋
i have this CI where i try to use a module to update some data and push it automatically based on a schedule 😏
but it fails with that kind of error 🤔
is it possible to
use
a module easily withsetup-nu
?i tried changing
NU_LIB_DIRS
to containpwd
but that did not work 👀The text was updated successfully, but these errors were encountered: