Parcourir la source

feat: remove master branch, switch to git merge --ff-only (#744)

* feat: remove master branch, switch to git merge --ff-only

* rename pr-to-latest.yml
Jacob Bolda il y a 5 ans
Parent
commit
92fc379921

+ 1 - 1
.github/CONTRIBUTING.md

@@ -31,7 +31,7 @@ Hi! We, the maintainers, are really excited that you are interested in contribut
 
 ## Pull Request Guidelines
 
-- The `master` branch is basically just a snapshot of the latest stable release. All development should be done in dedicated branches. **Do not submit PRs against the `master` branch.**
+- The `latest` branch is basically just a snapshot of the latest stable release. All development should be done in dedicated branches. **Do not submit PRs against the `latest` branch.**
 
 - Checkout a topic branch from the relevant branch, e.g. `dev`, and merge back against that branch.
 

+ 1 - 1
.github/PULL_REQUEST_TEMPLATE.md

@@ -30,7 +30,7 @@ If yes, please describe the impact and migration path for existing applications
 
 **The PR fulfills these requirements:**
 
-- [ ] It's submitted to the `dev` branch and _not_ the `master` branch
+- [ ] It's submitted to the `dev` branch and _not_ the `latest` branch
 - [ ] When resolving a specific issue, it's referenced in the PR's title (e.g. `fix: #xxx[,#xxx]`, where "xxx" is the issue number)
 - [ ] A change file is added if any packages will require a version bump due to this PR per [the instructions in the readme](https://github.com/tauri-apps/tauri/blob/dev/.changes/readme.md).
 

+ 1 - 1
.github/workflows/build-smoke-tests.yml

@@ -56,7 +56,7 @@ jobs:
         uses: actions/checkout@v2
         with:
           repository: tauri-apps/examples
-          ref: master
+          ref: latest
           path: examples
       - name: install rust stable
         uses: actions-rs/toolchain@v1

+ 1 - 1
.github/workflows/check-on-push.yml

@@ -3,7 +3,7 @@ name: clippy and eslint check
 on:
   push:
     branches-ignore:
-      - master
+      - latest
       - dev
 
 jobs:

+ 6 - 6
.github/workflows/pr-to-master.yml → .github/workflows/pr-to-latest.yml

@@ -1,4 +1,4 @@
-name: pr-to-master
+name: pr-to-latest
 
 on:
   push:
@@ -6,28 +6,28 @@ on:
       - dev
 
 jobs:
-  pr-to-master:
+  pr-to-latest:
     runs-on: ubuntu-latest
     if: contains(github.event.head_commit.message, 'version updates')
     steps:
       - uses: actions/checkout@v2
         with:
-          ref: master
+          ref: latest
       - name: git config
         run: |
           git config --global user.name "${{ github.event.pusher.name }}"
           git config --global user.email "${{ github.event.pusher.email }}"
       - run: git fetch origin dev
-      - run: git read-tree -u --reset ${{ github.sha }}
+      - run: git merge ${{ github.sha }} --ff-only
       - name: Create Pull Request
         uses: tauri-apps/create-pull-request@v2.8.0
         with:
           token: ${{ secrets.GITHUB_TOKEN }}
           commit-message: ${{ github.event.head_commit.message }}
-          branch: release/master
+          branch: release/latest
           branch-suffix: short-commit-hash
           title: Publish
           labels: "publish"
           body: |
-            Merging this PR will squash and push all changes to the master branch.
+            Merging this PR will squash and push all changes to the latest branch.
             It will kick off the process to release and publish any packages with an incremented version number.

+ 1 - 1
.github/workflows/pr-version-updates.yml

@@ -6,7 +6,7 @@ on:
       - dev
 
 jobs:
-  pr-to-master:
+  pr-to-latest:
     runs-on: ubuntu-latest
 
     steps:

+ 2 - 2
.github/workflows/release-cargo.yml

@@ -3,7 +3,7 @@ name: release-cargo
 on:
   push:
     branches:
-      - master
+      - latest
     paths:
       - '**/Cargo.toml'
       - '.github/workflows/**'
@@ -44,7 +44,7 @@ jobs:
     steps:
       - uses: actions/checkout@v2
         with:
-          ref: master
+          ref: latest
           toolchain: stable
       - name: get version
         working-directory: ${{ matrix.package.path }}

+ 2 - 2
.github/workflows/release-npm.yml

@@ -3,7 +3,7 @@ name: release-npm
 on:
   push:
     branches:
-      - master
+      - latest
     paths:
       - '**/package.json'
       - '.github/workflows/**'
@@ -21,7 +21,7 @@ jobs:
     steps:
       - uses: actions/checkout@v2
         with:
-          ref: master
+          ref: latest
       - uses: actions/setup-node@v1
         with:
           node-version: 12

+ 1 - 1
README.md

@@ -148,7 +148,7 @@ Documentation in a polyglot system is a tricky proposition. To this end, we pref
 Test all the things! We have a number of test suites, but are always looking to improve our coverage:
 - Rust (`cargo test`) => sourced via inline `#[cfg(test)]` declarations
 - TS (`jest`) => via spec files
-- Smoke Tests (run on merges to master)
+- Smoke Tests (run on merges to latest)
 - eslint, clippy
 
 ### CI/CD

+ 4 - 4
maskfile.md

@@ -2,11 +2,11 @@
 
 ## prepare
 
-> Setup all stuffs needed for runing the examples
+> Setup all stuffs needed for running the examples
 
 ```sh
 git clone --recursive git@github.com:tauri-apps/examples.git \
-|| (cd examples && git pull origin master; cd ..) 		# always prepare up-to-date examples in case it's already available
+|| (cd examples && git pull origin dev; cd ..) 		# always prepare up-to-date examples in case it's already available
 
 export TAURI_DIST_DIR=$PWD/tauri/test/fixture/dist
 export TAURI_DIR=$PWD/tauri/test/fixture/src-tauri
@@ -44,8 +44,8 @@ if (-Not (Test-Path $CWD\examples -PathType Any)) {
   } | Receive-Job -AutoRemoveJob -Wait
 }
 
-# Enter the examples folder and pull the latest data from origin/master
-cd examples; git pull origin master; cd ..
+# Enter the examples folder and pull the latest data from origin/dev
+cd examples; git pull origin dev; cd ..
 
 # Check that dist_path and src_path exist.
 if ((Test-Path $dist_path -PathType Any) -Or (Test-Path $src_path -PathType Any)) {