-
Notifications
You must be signed in to change notification settings - Fork 18
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
ci: Auto-determine checks to run #106
base: master
Are you sure you want to change the base?
Conversation
d188077
to
5a07c59
Compare
Hi ! There's a couple of things that confuses me.
|
YAML is sorta superset of JSON. And GitHub only supports
It is a helper script for generating the workflow. GitHub will ignore it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
Maybe this needs a rebase? |
Just did it. |
- name: Generate actions | ||
run: nix-shell .github/workflows/workflow-from-flake-checks.nix | ||
test: | ||
needs: | ||
- prepare-ci | ||
uses: ./.github/workflows/test.yaml | ||
secrets: inherit |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This does not do anything. If we decide to go the way of generated CI file, we should probably drop this file, or replace it with a check that the generated workflow is in sync with the checks.
description = "Build Xdebug extension"; | ||
drv = { php, ... }: php.extensions.xdebug; | ||
}; | ||
{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This probably needs to be a list so that we can have ordering.
}; | ||
} | ||
] | ||
++ lib.mapAttrsToList |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Or maybe it would be enough to add sort here, that would ensure php
test is first (not sure if there are any other dependencies – if yes, we should probably express them in checks.nix
and use toposort).
Exposing passhtru attributes as the derivation attributes is done by `stdenv.mkDerivation` so if we just add them to the passthru attribute of the resulting derivation attrset, they will be only available inside the passthru attribute. We can just append those attributes to the derivation attrset directly, it won’t affect the derivation either way.
This will basically allow us to treat `checks.nix` like something that supports having its dependencies injected by `callPackages`, allowing us to simplify the expression a bit. It will also allow other scripts to get the check names trivially.
This will allow us to support multiple platforms easily.
This will allow us to support multiple platforms easily.
Still some issues:
php.extensions.mysql
socket test running first will buildphp.unwrapped
and, if that fails, it will look like the socket test failed. But not sure what to do about that.Supersedes: #85