From 2643348a3ee73899d2f1b5f6c54a79fe26352efc Mon Sep 17 00:00:00 2001 From: Ulthran Date: Tue, 2 Apr 2024 13:22:16 -0400 Subject: [PATCH 1/3] Replace line breaks with commas for installed_packages.txt --- .github/workflows/dockerhub.yml | 23 ++++++----------------- Dockerfile | 2 +- slim.Dockerfile | 2 +- workflow/envs/cutadapt.Dockerfile | 2 +- workflow/envs/komplexity.Dockerfile | 2 +- workflow/envs/qc.Dockerfile | 2 +- workflow/envs/reports.Dockerfile | 2 +- 7 files changed, 12 insertions(+), 23 deletions(-) diff --git a/.github/workflows/dockerhub.yml b/.github/workflows/dockerhub.yml index 837e7dc1..0a55e90d 100644 --- a/.github/workflows/dockerhub.yml +++ b/.github/workflows/dockerhub.yml @@ -99,12 +99,9 @@ jobs: - name: Generate image report id: report - # Replace '\n' with '%0A' for embedding into release notes (for somer reason '\n' is not escaped) run: | - IP=$(docker run --rm sunbeamlabs/sunbeam:${{ inputs.version }} cat installed_packages.txt) - echo "package_versions=${IP//$'\n'/'%0A'}" >> "$GITHUB_OUTPUT" - IP=$(docker run --rm sunbeamlabs/sunbeam:${{ inputs.version }}-slim cat installed_packages.txt) - echo "package_versions_slim=${IP//$'\n'/'%0A'}" >> "$GITHUB_OUTPUT" + echo "package_versions=$(docker run --rm sunbeamlabs/sunbeam:${{ inputs.version }} cat installed_packages.txt)" >> "$GITHUB_OUTPUT" + echo "package_versions_slim=$(docker run --rm sunbeamlabs/sunbeam:${{ inputs.version }}-slim cat installed_packages.txt)" >> "$GITHUB_OUTPUT" push-cutadapt-dockerhub: name: Push cutadapt env to Dockerhub @@ -140,9 +137,7 @@ jobs: - name: Generate image report id: report run: | - IP=$(docker run --rm sunbeamlabs/cutadapt:${{ inputs.version }} cat installed_packages.txt) - echo $IP - echo "package_versions=${IP//$'\n'/'%0A'}" >> "$GITHUB_OUTPUT" + echo "package_versions=$(docker run --rm sunbeamlabs/cutadapt:${{ inputs.version }} cat installed_packages.txt)" >> "$GITHUB_OUTPUT" push-komplexity-dockerhub: name: Push komplexity env to Dockerhub @@ -178,9 +173,7 @@ jobs: - name: Generate image report id: report run: | - IP=$(docker run --rm sunbeamlabs/komplexity:${{ inputs.version }} cat installed_packages.txt) - echo $IP - echo "package_versions=${IP//$'\n'/'%0A'}" >> "$GITHUB_OUTPUT" + echo "package_versions=$(docker run --rm sunbeamlabs/komplexity:${{ inputs.version }} cat installed_packages.txt)" >> "$GITHUB_OUTPUT" push-qc-dockerhub: name: Push qc env to Dockerhub @@ -216,9 +209,7 @@ jobs: - name: Generate image report id: report run: | - IP=$(docker run --rm sunbeamlabs/qc:${{ inputs.version }} cat installed_packages.txt) - echo $IP - echo "package_versions=${IP//$'\n'/'%0A'}" >> "$GITHUB_OUTPUT" + echo "package_versions=$(docker run --rm sunbeamlabs/qc:${{ inputs.version }} cat installed_packages.txt)" >> "$GITHUB_OUTPUT" push-reports-dockerhub: name: Push reports env to Dockerhub @@ -254,6 +245,4 @@ jobs: - name: Generate image report id: report run: | - IP=$(docker run --rm sunbeamlabs/reports:${{ inputs.version }} cat installed_packages.txt) - echo $IP - echo "package_versions=${IP//$'\n'/'%0A'}" >> "$GITHUB_OUTPUT" \ No newline at end of file + echo "package_versions=$(docker run --rm sunbeamlabs/reports:${{ inputs.version }} cat installed_packages.txt)" >> "$GITHUB_OUTPUT" \ No newline at end of file diff --git a/Dockerfile b/Dockerfile index 72bbb0f6..209eca30 100644 --- a/Dockerfile +++ b/Dockerfile @@ -40,7 +40,7 @@ RUN rm -r projects # "Activate" the environment SHELL ["conda", "run", "-n", "sunbeam", "/bin/bash", "-c"] -RUN echo "Python: $(python --version)\nSnakemake: $(snakemake --version)\nConda: $(conda --version)" > installed_packages.txt +RUN echo "Python: $(python --version), Snakemake: $(snakemake --version), Conda: $(conda --version)" > installed_packages.txt # Run CMD "bash" \ No newline at end of file diff --git a/slim.Dockerfile b/slim.Dockerfile index 9a84c0ce..85ce3808 100644 --- a/slim.Dockerfile +++ b/slim.Dockerfile @@ -34,7 +34,7 @@ ENV SUNBEAM_MIN_RUNTIME="60" # "Activate" the environment SHELL ["conda", "run", "-n", "sunbeam", "/bin/bash", "-c"] -RUN echo "Python: $(python --version)\nSnakemake: $(snakemake --version)\nConda: $(conda --version)" > installed_packages.txt +RUN echo "Python: $(python --version), Snakemake: $(snakemake --version), Conda: $(conda --version)" > installed_packages.txt # Run CMD "bash" \ No newline at end of file diff --git a/workflow/envs/cutadapt.Dockerfile b/workflow/envs/cutadapt.Dockerfile index ff4186da..861d529f 100644 --- a/workflow/envs/cutadapt.Dockerfile +++ b/workflow/envs/cutadapt.Dockerfile @@ -6,7 +6,7 @@ WORKDIR /home/cutadapt_env # Install environment RUN pip install cutadapt -RUN echo "Python: $(python --version)\nCutadapt $(pip show cutadapt | grep 'Version: ')" > installed_packages.txt +RUN echo "Python: $(python --version), Cutadapt $(pip show cutadapt | grep 'Version: ')" > installed_packages.txt # Run CMD ["bash"] \ No newline at end of file diff --git a/workflow/envs/komplexity.Dockerfile b/workflow/envs/komplexity.Dockerfile index b299ff31..c794851a 100644 --- a/workflow/envs/komplexity.Dockerfile +++ b/workflow/envs/komplexity.Dockerfile @@ -8,7 +8,7 @@ RUN apt-get update && apt-get install -y git RUN git clone https://github.com/eclarke/komplexity RUN cd komplexity && cargo install -RUN echo "Rustc: $(rustc --version)\nKomplexity $(kz --version)" > installed_packages.txt +RUN echo "Rustc: $(rustc --version), Komplexity $(kz --version)" > installed_packages.txt # Run CMD ["bash"] \ No newline at end of file diff --git a/workflow/envs/qc.Dockerfile b/workflow/envs/qc.Dockerfile index 98dba1f9..f14ec718 100644 --- a/workflow/envs/qc.Dockerfile +++ b/workflow/envs/qc.Dockerfile @@ -13,7 +13,7 @@ ENV PATH="/opt/conda/envs/qc/bin/:${PATH}" # "Activate" the environment SHELL ["conda", "run", "--no-capture-output", "-n", "qc", "/bin/bash", "-c"] -RUN echo "Python: $(python --version)\nConda: $(conda --version)\nBWA: $(bwa 2>&1 >/dev/null | grep 'Version: ')\nFastQC: $(fastqc --version)\nTrimmomatic: $(trimmomatic -version)" > installed_packages.txt +RUN echo "Python: $(python --version), Conda: $(conda --version), BWA: $(bwa 2>&1 >/dev/null | grep 'Version: '), FastQC: $(fastqc --version), Trimmomatic: $(trimmomatic -version)" > installed_packages.txt # Run CMD "bash" \ No newline at end of file diff --git a/workflow/envs/reports.Dockerfile b/workflow/envs/reports.Dockerfile index 1b9f3716..7010f389 100644 --- a/workflow/envs/reports.Dockerfile +++ b/workflow/envs/reports.Dockerfile @@ -6,7 +6,7 @@ WORKDIR /home/reports_env # Install environment RUN pip install numpy pandas -RUN echo "Python: $(python --version)\nNumpy $(pip show numpy | grep 'Version: ')\nPandas $(pip show pandas | grep 'Version: ')" > installed_packages.txt +RUN echo "Python: $(python --version), Numpy $(pip show numpy | grep 'Version: '), Pandas $(pip show pandas | grep 'Version: ')" > installed_packages.txt # Run CMD ["bash"] \ No newline at end of file From e26a9b8a4e7278ddcfd16c7be85874fde80e1748 Mon Sep 17 00:00:00 2001 From: Ulthran Date: Tue, 2 Apr 2024 13:23:29 -0400 Subject: [PATCH 2/3] Bump version to v4.5.2.dev5 --- install.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install.sh b/install.sh index 92399f21..45a47327 100755 --- a/install.sh +++ b/install.sh @@ -1,7 +1,7 @@ #!/usr/bin/env bash __conda_url=https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -__version_tag=$(if git describe --tags >/dev/null 2>&1 ; then git describe --tags; else echo v4.5.2.dev4; fi) # <--- Update this on each version release +__version_tag=$(if git describe --tags >/dev/null 2>&1 ; then git describe --tags; else echo v4.5.2.dev5; fi) # <--- Update this on each version release __version_tag="${__version_tag:1}" # Remove the 'v' prefix read -r -d '' __usage <<-'EOF' From d617923e37e8162d6bdb41d9ce2994d6f115807b Mon Sep 17 00:00:00 2001 From: Ulthran Date: Thu, 4 Apr 2024 11:48:36 -0400 Subject: [PATCH 3/3] Remove tar generation and attachment --- .github/PULL_REQUEST_TEMPLATE.md | 3 ++- .github/workflows/release.yml | 30 ------------------------------ 2 files changed, 2 insertions(+), 31 deletions(-) diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index a6c3c9d7..906e1fb3 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -5,4 +5,5 @@ If this is for a release: * [ ] I have updated documentation -* [ ] I have updated the hardcoded version at the top of `install.sh` to match what this release's version will be \ No newline at end of file +* [ ] I have updated the hardcoded version at the top of `install.sh` to match what this release's version will be +* [ ] I have created a release archive that will be attached to this release (`bash dev_scripts/generate_archive.sh`) \ No newline at end of file diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index d7de1f15..36fe1129 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -44,35 +44,6 @@ jobs: echo "Versions don't match, exiting..." exit 1 fi - - generate-tarball: - name: Generate Tarball and Add to Release - runs-on: ubuntu-latest - needs: - - run-tests - - check-version - - steps: - - name: Checkout Code - uses: actions/checkout@v4 - - - name: Generate Tarball - run: bash dev_scripts/generate_archive.sh - - - name: Upload Tarball - uses: actions/upload-artifact@v2 - with: - name: sunbeam.tar.gz - path: sunbeam.tar.gz - - - name: Add Tarball to Release - uses: irongut/EditRelease@v1.2.0 - with: - token: ${{ secrets.GITHUB_TOKEN }} - id: ${{ github.event.release.id }} - body: "### Sunbeam Tarball\nDownload the Sunbeam tarball from the release page to install Sunbeam locally.\n[Download Sunbeam Tarball](https://github.com/sunbeam-labs/sunbeam/releases/${{ needs.check-version.outputs.version }}/download/sunbeam.tar.gz" - replacebody: false - files: "sunbeam.tar.gz" test-tarball: name: Test Tarball @@ -80,7 +51,6 @@ jobs: needs: - run-tests - check-version - - generate-tarball steps: - name: setup-conda