Skip to content
This repository has been archived by the owner on Jul 30, 2024. It is now read-only.

Commit

Permalink
build: COPY stop repeating target location (#104)
Browse files Browse the repository at this point in the history
  • Loading branch information
DeveloperC286 authored Apr 14, 2024
1 parent c5c26b7 commit 9b13be7
Showing 1 changed file with 7 additions and 10 deletions.
17 changes: 7 additions & 10 deletions Earthfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,14 @@ VERSION 0.7

COPY_CI_DATA:
COMMAND
COPY "./ci" "./ci"
COPY ".github" ".github"
COPY ".goreleaser.yaml" ".goreleaser.yaml"
COPY --dir "ci/" ".github/" "./"
COPY ".goreleaser.yaml" "./"


COPY_METADATA:
COMMAND
DO +COPY_CI_DATA
COPY ".git" ".git"
COPY --dir ".git/" "./"


rust-base:
Expand All @@ -37,16 +36,14 @@ check-conventional-commits-linting:

INSTALL_DEPENDENCIES:
COMMAND
COPY "go.mod" "go.mod"
COPY "go.sum" "go.sum"
COPY "go.mod" "go.sum" "./"
RUN go mod download


COPY_SOURCECODE:
COMMAND
DO +COPY_CI_DATA
COPY "./cmd" "./cmd"
COPY "./api" "./api"
COPY --dir "cmd/" "api/" "./"


golang-base:
Expand Down Expand Up @@ -79,7 +76,7 @@ check-shell-formatting:
yaml-formatting-base:
FROM +golang-base
RUN go install github.com/google/yamlfmt/cmd/[email protected]
COPY ".yamlfmt" ".yamlfmt"
COPY ".yamlfmt" "./"
DO +COPY_CI_DATA


Expand Down Expand Up @@ -208,7 +205,7 @@ release-artifacts:
FROM +ubuntu-base
RUN apt-get install git wget jq -y
DO +INSTALL_GITHUB_CLI
COPY +compile/dist ./dist
COPY "+compile/dist/" "./"
DO +COPY_METADATA
ARG release
RUN --secret GH_TOKEN ./ci/release-artifacts.sh --release "${release}"

0 comments on commit 9b13be7

Please sign in to comment.