-
-
Notifications
You must be signed in to change notification settings - Fork 113
35 lines (29 loc) · 878 Bytes
/
main.yml
File metadata and controls
35 lines (29 loc) · 878 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
name: Mirror to SourceForge
on:
push:
branches:
- master
jobs:
mirror:
runs-on: ubuntu-latest
steps:
- name: Checkout Code
uses: actions/checkout@v4
with:
fetch-depth: 0 # Perform a full clone instead of a shallow clone
- name: Setup SSH
run: |
mkdir -p ~/.ssh
chmod 700 ~/.ssh
echo "${{ secrets.SOURCEFORGE_SSH_KEY }}" > ~/.ssh/id_rsa
chmod 600 ~/.ssh/id_rsa
ssh-keyscan git.code.sf.net >> ~/.ssh/known_hosts
- name: Configure Git Remote
run: |
echo "Checking Git remote..."
git remote add sourceforge ssh://jessuppi@git.code.sf.net/p/slickstack/code
git remote -v
- name: Push to SourceForge
run: |
echo "Pushing code to SourceForge..."
git push sourceforge master --force