From bc1d047359c46b146b0a41a5012ce120cb56ba3d Mon Sep 17 00:00:00 2001 From: Marc Beninca Date: Mon, 14 Oct 2024 22:14:23 +0200 Subject: [PATCH 1/3] actions/synchronize --- spcd/actions/synchronize/action.yaml | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 spcd/actions/synchronize/action.yaml diff --git a/spcd/actions/synchronize/action.yaml b/spcd/actions/synchronize/action.yaml new file mode 100644 index 0000000..5b07c73 --- /dev/null +++ b/spcd/actions/synchronize/action.yaml @@ -0,0 +1,8 @@ +inputs: + source: + default: out + required: false +runs: + using: composite + steps: + - run: echo "${INPUT_SOURCE}" From 52835704bfd1fa8f2486ea88c5cec045ab4614d1 Mon Sep 17 00:00:00 2001 From: Marc Beninca Date: Mon, 14 Oct 2024 22:18:47 +0200 Subject: [PATCH 2/3] sync/context --- spcd/actions/synchronize/action.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/spcd/actions/synchronize/action.yaml b/spcd/actions/synchronize/action.yaml index 5b07c73..a74a2e7 100644 --- a/spcd/actions/synchronize/action.yaml +++ b/spcd/actions/synchronize/action.yaml @@ -5,4 +5,5 @@ inputs: runs: using: composite steps: - - run: echo "${INPUT_SOURCE}" + - run: echo "synchronize" + - run: echo " source: ${INPUT_SOURCE}" From 3e494bc354bf6fa01bd75a6d47119d64c14c805e Mon Sep 17 00:00:00 2001 From: Marc Beninca Date: Mon, 14 Oct 2024 22:43:07 +0200 Subject: [PATCH 3/3] act --- spcd/__init__.py | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/spcd/__init__.py b/spcd/__init__.py index 4b9b6a5..41b6927 100644 --- a/spcd/__init__.py +++ b/spcd/__init__.py @@ -44,6 +44,16 @@ def clone_project_branch() -> None: ) +def install_actions(path: Path) -> None: + """Make actions usable in workflows. + + :param path: entry point file + :type path: Path + """ + step("Install actions") + Path("act").symlink_to(path.parent / "actions") + + def install_commands(path: Path) -> None: """Make commands callable in the operating system. @@ -113,6 +123,7 @@ def main(main_file: Path) -> None: list_environment_variables() clone_project_branch() set_ssh() + install_actions(main_file) install_commands(main_file) install_python_packages() else: