Skip to content

Commit

Permalink
bump version to 1.0.2, update 'app' branch reset logic
Browse files Browse the repository at this point in the history
  • Loading branch information
bullet-ant committed Sep 15, 2024
1 parent 8757a30 commit 1b8cd0b
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 8 deletions.
10 changes: 7 additions & 3 deletions .github/workflows/docker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@ jobs:
# Step 1: Checkout the 'app' branch code
- name: Checkout app branch code
uses: actions/checkout@v4
with:
ref: app

# Step 2: Install jq to parse package.json
- name: Install jq
Expand Down Expand Up @@ -79,7 +77,13 @@ jobs:
echo "VERSION_CHANGED=false" >> $GITHUB_ENV
fi
# Step 11: Create a Pull Request only if the version changed and Docker image was built successfully
# Step 11: Reset 'app' branch to the latest code
- name: Reset app branch
run: |
git fetch origin app
git reset --hard origin/app
# Step 12: Create a Pull Request only if the version changed and Docker image was built successfully
- name: Create Pull Request
if: success() && env.VERSION_CHANGED == 'true'
uses: peter-evans/create-pull-request@v7
Expand Down
2 changes: 1 addition & 1 deletion app/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "app",
"private": true,
"version": "1.0.1",
"version": "1.0.2",
"type": "module",
"scripts": {
"dev": "vite",
Expand Down
3 changes: 2 additions & 1 deletion app/src/App.svelte
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
<script>
import "./app.css";
import pkg from "../package.json";
let src =
"https://i.pinimg.com/736x/df/cf/3f/dfcf3f48ab61f0ed8857676a441859dc--doge-meme-doge-dog.jpg";
</script>

<main>
<img {src} alt="a legendary meme" />
<h1>v1.0.0</h1>
<h1>v{pkg.version}</h1>
</main>

<style>
Expand Down
10 changes: 7 additions & 3 deletions app/vite.config.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
import { defineConfig } from 'vite'
import { svelte } from '@sveltejs/vite-plugin-svelte'
import { defineConfig } from "vite";
import { svelte } from "@sveltejs/vite-plugin-svelte";

// https://vitejs.dev/config/
export default defineConfig({
plugins: [svelte()],
})
json: {
namedExports: true,
stringify: false,
},
});

0 comments on commit 1b8cd0b

Please sign in to comment.