Skip to content

GitHub private fork #21

@jschenke488

Description

@jschenke488
name: hehe

on:
  workflow_dispatch:
  schedule:
    - cron: '0 10 * * *'

jobs:
  hehe:
    runs-on: ubuntu-latest
    if: github.repository == 'FRCTeam1987/3061-lib'

    steps:
      - name: Run a multi-line script
        run: |
          git config --global user.name "Jay"
          git config --global user.email "jschenke488@lsr7.net"
          git clone --mirror https://github.com/jschenke488/3061-lib 3061-lib
          cd 3061-lib
          git remote remove origin
          git remote add origin https://jschenke488:${{ secrets.GIT_TOKEN }}@github.com/FRCTeam1987/3061-lib
          git push -f --prune --all
          git push -f --prune --tag

This GitHub action can be put inside a blank private repository and then that private repo can be forked to create a private fork. It's stupid, but it works.

Metadata

Metadata

Assignees

Labels

enhancementNew feature or requestforlaterSomething for later

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions