diff --git a/spcd/__init__.py b/spcd/__init__.py index ad58e1d..eccad81 100644 --- a/spcd/__init__.py +++ b/spcd/__init__.py @@ -52,17 +52,22 @@ def install_actions(path: Path) -> None: """ step("Install actions") name = "action.yaml" - source = path.parent / "actions" - target = project.root / "act" - for action in [ - "synchronize", - ]: - log.info(action) - r = source / action / name - w = target / action - fs.make_directory(w) - w = w / name - fs.write(w, fs.read_file_text(r)) + root = project.root / "act" + vpy = Path(env.SPCD_PYTHON_VENV_BINARIES) / "python" + action = "synchronize" + log.info(action) + directory = root / action + fs.make_directory(directory) + fs.write(directory / name, f"""\ +inputs: + source: + default: out + required: false +runs: + using: composite + steps: + - run: "{vpy}" -m spcd synchronize +""") def install_commands(path: Path) -> None: diff --git a/spcd/actions/synchronize/action.yaml b/spcd/actions/synchronize/action.yaml deleted file mode 100644 index 46526be..0000000 --- a/spcd/actions/synchronize/action.yaml +++ /dev/null @@ -1,8 +0,0 @@ -inputs: - source: - default: out - required: false -runs: - using: composite - steps: - - run: python3 -m "spcd" "synchronize"