Skip to content

Commit 1a47e83

Browse files
committed
update
1 parent 4ae8e8e commit 1a47e83

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

.github/scripts/depexts/generate-actions.sh

+14-1
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,7 @@ EOF
106106
cat >$dir/Dockerfile << EOF
107107
FROM nixos/nix
108108
RUN nix-channel --update
109+
RUN nix-shell -p gnum4 git rsync patch gnutar bzip2 gnumake wget ocamlPackages.ocaml ocamlPackages.ocaml-compiler-libs unzip
109110
EOF
110111
esac
111112

@@ -137,7 +138,7 @@ ENTRYPOINT ["/opam/entrypoint.sh"]
137138
EOF
138139
else
139140
cat >>$dir/Dockerfile << EOF
140-
ENTRYPOINT ["nix-shell", "-p", "gnum4", "git", "rsync", "patch", "gnutar", "bzip2", "gnumake", "wget", "ocamlPackages.ocaml", "ocamlPackages.ocaml-compiler-libs", "opam", "--run", "/opam/entrypoint.sh"]
141+
ENTRYPOINT ["nix-shell", "-p", "gnum4", "git", "rsync", "patch", "gnutar", "bzip2", "gnumake", "wget", "ocamlPackages.ocaml", "ocamlPackages.ocaml-compiler-libs", "unzip", "--run", "/opam/entrypoint.sh"]
141142
EOF
142143
fi
143144

@@ -146,6 +147,18 @@ cat >$dir/entrypoint.sh << EOF
146147
#!/bin/sh
147148
set -eux
148149
150+
EOF
151+
152+
if [ "$target" != "nix" ]; then
153+
cat >>$dir/entrypoint.sh << EOF
154+
export PATH="$PATH:/usr/bin/"
155+
chmod +x /usr/bin/opam
156+
157+
EOF
158+
fi
159+
160+
### Generate the entrypoint
161+
cat >$dir/entrypoint.sh << EOF
149162
git config --global --add safe.directory /github/workspace
150163
151164
# Workdir is /github/workpaces

0 commit comments

Comments
 (0)