mirror of
https://gitlab.com/lecarore/breakout71.git
synced 2025-04-26 23:16:15 -04:00
Automatic deploy 28994149
This commit is contained in:
parent
fd9ac99e5b
commit
4468c029db
4 changed files with 12 additions and 13 deletions
|
@ -15,8 +15,8 @@ android {
|
|||
applicationId = "me.lecaro.breakout"
|
||||
minSdk = 21
|
||||
targetSdk = 34
|
||||
versionCode = 28994147
|
||||
versionName = "2025-02-15 20:47:26"
|
||||
versionCode = 28994149
|
||||
versionName = "28994149"
|
||||
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
|
||||
vectorDrawables {
|
||||
useSupportLibrary = true
|
||||
|
|
|
@ -8,14 +8,14 @@
|
|||
/>
|
||||
<meta http-equiv="X-UA-Compatible" content="ie=edge" />
|
||||
<title>Breakout 𝟕𝟏</title>
|
||||
<link rel="stylesheet" href="style.css?v=6294" />
|
||||
<link rel="stylesheet" href="style.css?v=28994149" />
|
||||
<link rel="icon" href="./icon.svg" />
|
||||
</head>
|
||||
<body>
|
||||
<button id="menu">☰<span> menu</span></button>
|
||||
<button id="score"></button>
|
||||
<canvas id="game"></canvas>
|
||||
<script src="levels.js?v=6294"></script>
|
||||
<script src="game.js?v=6294"></script>
|
||||
<script src="levels.js?v=28994149"></script>
|
||||
<script src="game.js?v=28994149"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
BIN
breakout.zip
BIN
breakout.zip
Binary file not shown.
15
deploy.sh
15
deploy.sh
|
@ -1,19 +1,18 @@
|
|||
#!/bin/bash
|
||||
|
||||
# Invalidate web cache
|
||||
# Generate a random number between 1000 and 9999
|
||||
random_number=$(shuf -i 1000-9999 -n 1)
|
||||
# Use sed to replace the pattern with the random number
|
||||
sed -i "s/\?v=[0-9]*/\?v=$random_number/g" ./app/src/main/assets/index.html
|
||||
|
||||
|
||||
# Replace the version code and name in gradle for fdroid and play store
|
||||
versionCode=$(($(date +%s) / 60))
|
||||
versionName=$(date +"%Y-%m-%d %H:%M:%S")
|
||||
sed -i '' -e "s/^[[:space:]]*versionCode = .*/ versionCode = $versionCode/" \
|
||||
-e "s/^[[:space:]]*versionName = .*/ versionName = \"$versionName\"/" \
|
||||
-e "s/^[[:space:]]*versionName = .*/ versionName = \"$versionCode\"/" \
|
||||
./app/build.gradle.kts
|
||||
|
||||
|
||||
|
||||
# Invalidate web cache
|
||||
sed -i "s/\?v=[0-9]*/\?v=$versionCode/g" ./app/src/main/assets/index.html
|
||||
|
||||
|
||||
git add .
|
||||
git commit -m "Automatic deploy $versionCode"
|
||||
git tag -f $versionCode
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue