Selaa lähdekoodia

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 5 vuotta sitten
vanhempi
sitoutus
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
 ## 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.
 - 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:**
 **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)
 - [ ] 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).
 - [ ] 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
         uses: actions/checkout@v2
         with:
         with:
           repository: tauri-apps/examples
           repository: tauri-apps/examples
-          ref: master
+          ref: latest
           path: examples
           path: examples
       - name: install rust stable
       - name: install rust stable
         uses: actions-rs/toolchain@v1
         uses: actions-rs/toolchain@v1

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

@@ -3,7 +3,7 @@ name: clippy and eslint check
 on:
 on:
   push:
   push:
     branches-ignore:
     branches-ignore:
-      - master
+      - latest
       - dev
       - dev
 
 
 jobs:
 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:
 on:
   push:
   push:
@@ -6,28 +6,28 @@ on:
       - dev
       - dev
 
 
 jobs:
 jobs:
-  pr-to-master:
+  pr-to-latest:
     runs-on: ubuntu-latest
     runs-on: ubuntu-latest
     if: contains(github.event.head_commit.message, 'version updates')
     if: contains(github.event.head_commit.message, 'version updates')
     steps:
     steps:
       - uses: actions/checkout@v2
       - uses: actions/checkout@v2
         with:
         with:
-          ref: master
+          ref: latest
       - name: git config
       - name: git config
         run: |
         run: |
           git config --global user.name "${{ github.event.pusher.name }}"
           git config --global user.name "${{ github.event.pusher.name }}"
           git config --global user.email "${{ github.event.pusher.email }}"
           git config --global user.email "${{ github.event.pusher.email }}"
       - run: git fetch origin dev
       - run: git fetch origin dev
-      - run: git read-tree -u --reset ${{ github.sha }}
+      - run: git merge ${{ github.sha }} --ff-only
       - name: Create Pull Request
       - name: Create Pull Request
         uses: tauri-apps/create-pull-request@v2.8.0
         uses: tauri-apps/create-pull-request@v2.8.0
         with:
         with:
           token: ${{ secrets.GITHUB_TOKEN }}
           token: ${{ secrets.GITHUB_TOKEN }}
           commit-message: ${{ github.event.head_commit.message }}
           commit-message: ${{ github.event.head_commit.message }}
-          branch: release/master
+          branch: release/latest
           branch-suffix: short-commit-hash
           branch-suffix: short-commit-hash
           title: Publish
           title: Publish
           labels: "publish"
           labels: "publish"
           body: |
           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.
             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
       - dev
 
 
 jobs:
 jobs:
-  pr-to-master:
+  pr-to-latest:
     runs-on: ubuntu-latest
     runs-on: ubuntu-latest
 
 
     steps:
     steps:

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

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

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

@@ -3,7 +3,7 @@ name: release-npm
 on:
 on:
   push:
   push:
     branches:
     branches:
-      - master
+      - latest
     paths:
     paths:
       - '**/package.json'
       - '**/package.json'
       - '.github/workflows/**'
       - '.github/workflows/**'
@@ -21,7 +21,7 @@ jobs:
     steps:
     steps:
       - uses: actions/checkout@v2
       - uses: actions/checkout@v2
         with:
         with:
-          ref: master
+          ref: latest
       - uses: actions/setup-node@v1
       - uses: actions/setup-node@v1
         with:
         with:
           node-version: 12
           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:
 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
 - Rust (`cargo test`) => sourced via inline `#[cfg(test)]` declarations
 - TS (`jest`) => via spec files
 - TS (`jest`) => via spec files
-- Smoke Tests (run on merges to master)
+- Smoke Tests (run on merges to latest)
 - eslint, clippy
 - eslint, clippy
 
 
 ### CI/CD
 ### CI/CD

+ 4 - 4
maskfile.md

@@ -2,11 +2,11 @@
 
 
 ## prepare
 ## prepare
 
 
-> Setup all stuffs needed for runing the examples
+> Setup all stuffs needed for running the examples
 
 
 ```sh
 ```sh
 git clone --recursive git@github.com:tauri-apps/examples.git \
 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_DIST_DIR=$PWD/tauri/test/fixture/dist
 export TAURI_DIR=$PWD/tauri/test/fixture/src-tauri
 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
   } | 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.
 # Check that dist_path and src_path exist.
 if ((Test-Path $dist_path -PathType Any) -Or (Test-Path $src_path -PathType Any)) {
 if ((Test-Path $dist_path -PathType Any) -Or (Test-Path $src_path -PathType Any)) {