Skip to content

Commit e70c17f

Browse files
author
Frederic Spiers
committed
feat(sh): add contrib script
1 parent d9e4437 commit e70c17f

File tree

2 files changed

+45
-1
lines changed

2 files changed

+45
-1
lines changed

charts/minio/templates/configmap.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ metadata:
55
name: {{ include "minio.fullname" . }}
66
namespace: {{ .Release.Namespace }}
77
labels:
8-
app: test
98
{{- include "minio.labels" . | nindent 4 }}
109
{{- if .Values.commonAnnotations }}
1110
annotations:

contrib.sh

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
#!/bin/bash
2+
3+
ACTION=$1
4+
BRANCH_NAME=$2
5+
6+
if [ -z "$BRANCH_NAME" ]; then
7+
echo "Usage: $0 <branch-name> [start|finish|update]"
8+
echo " start: Start new contribution"
9+
echo " finish: Restore private workflows"
10+
exit 1
11+
fi
12+
13+
case $ACTION in
14+
"start")
15+
echo "🔄 Synchronisation with upstream..."
16+
git checkout main
17+
18+
git fetch upstream
19+
git diff upstream/main -- .github/workflows/ > private-workflows.patch
20+
21+
echo "🗑️ Deleting private workflows before contrib..."
22+
git apply -R private-workflows.patch
23+
echo "✅ Private workflows deleted"
24+
25+
echo "🌿 Creating branch $BRANCH_NAME..."
26+
git checkout -b "$BRANCH_NAME"
27+
28+
echo "✅ Ready for contrib !"
29+
;;
30+
31+
"finish")
32+
echo "🔄 Return to main..."
33+
git checkout main
34+
35+
echo "🔧 Restore private workflows..."
36+
git apply private-workflows.patch
37+
38+
echo "✅ Ready !"
39+
;;
40+
41+
*)
42+
echo "Action inconnue: $ACTION"
43+
echo "Utilisez: start or finish"
44+
;;
45+
esac

0 commit comments

Comments
 (0)