Skip to content
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

Add hint to reproduce the devshell flavor locally if within GitHub Action #138

Merged
merged 1 commit into from
Apr 4, 2024

Conversation

yvan-sraka
Copy link
Contributor

@yvan-sraka yvan-sraka commented Apr 3, 2024

As suggested by @angerman, in response to issues that @erikd and @sgillespie got while debugging db-sync actions.

The output looks like:

% export GITHUB_ACTIONS=true
% nix develop ".#ghc96"     
                                                                     
 _____ _____ _____    _____         _       _ _    _____ _       _ _ 
|     |     |   __|  |  |  |___ ___| |_ ___| | |  |   __| |_ ___| | |
|-   -|  |  |  |  |  |     | .'|_ -| '_| -_| | |  |__   |   | -_| | |
|_____|_____|_____|  |__|__|__,|___|_,_|___|_|_|  |_____|_|_|___|_|_|
                                                                     
Revision (input-output-hk/devx): 6b241faf9b5ebe1fbbfbd56d0cf96867bf8477e9.
CABAL_DIR set to /Users/yvan/.cabal-devx

Hint: to reproduce this environment locally, use either:
$ nix develop github:input-output-hk/devx#ghc963
$ docker run -it -v $(pwd):/workspaces ghcr.io/input-output-hk/devx-devcontainer:x86_64-linux.ghc963

(nix:nix-shell-env)040[~/GitHub/devx]$ 

@yvan-sraka yvan-sraka requested a review from angerman April 3, 2024 14:48
@yvan-sraka yvan-sraka self-assigned this Apr 3, 2024
@yvan-sraka yvan-sraka force-pushed the hint-to-reproduce-devshell-locally-on-gha branch 3 times, most recently from 4598fce to 6b241fa Compare April 3, 2024 15:25
Copy link
Collaborator

@angerman angerman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

isn't if x then str else "" just optional x str?

quirks.nix Outdated Show resolved Hide resolved
@angerman
Copy link
Collaborator

angerman commented Apr 4, 2024

I wonder if there was something to emit some other Note/Info/Error thing in GHA.

Yes, something like

echo "::notice::Notice message here"

seems to be supposed to work?
https://docs.github.com/en/actions/using-workflows/workflow-commands-for-github-actions#setting-a-notice-message

@yvan-sraka
Copy link
Contributor Author

isn't if x then str else "" just optional x str?

You right there is a nixpkgs.lib.optionalString thing :)

cross-js.nix Outdated Show resolved Hide resolved
@yvan-sraka yvan-sraka force-pushed the hint-to-reproduce-devshell-locally-on-gha branch from 1c3996d to 75de496 Compare April 4, 2024 10:35
…tion

Co-authored by @angerman that got the original idea and improve the style of the Nix expressions
@yvan-sraka yvan-sraka force-pushed the hint-to-reproduce-devshell-locally-on-gha branch from 75de496 to 6541d98 Compare April 4, 2024 10:45
@yvan-sraka yvan-sraka added this pull request to the merge queue Apr 4, 2024
Merged via the queue into main with commit db7ea17 Apr 4, 2024
51 checks passed
@yvan-sraka yvan-sraka deleted the hint-to-reproduce-devshell-locally-on-gha branch April 4, 2024 17:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants