Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

COMMIT_LIST=$(git log --pretty=format:"* %s (%h) by %an" origin/master..rc |
COMMIT_LIST=$(git log --pretty=format:"* %s (%h) by %an" origin/main..rc |
while IFS= read -r line; do
if [[ ! $line =~ ^"* feat"* && ! $line =~ ^"* fix"* && ! $line =~ ^"* docs"* ]]; then
echo "* chore${line:1}"
Expand All @@ -19,7 +19,7 @@ echo "$COMMIT_LIST" >commit_list.txt

cat <<EOF >>$GITHUB_ENV
PR_BODY<<EOT
This is an automated PR to promote changes from \`rc\` to \`master\`.
This is an automated PR to promote changes from \`rc\` to \`main\`.
Please review and test before merging.

See [TESTING.md](./TESTING.md) for complete testing instructions.
Expand Down
44 changes: 22 additions & 22 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ on:
push:
branches:
- dev
- master
- main
- rc
pull_request:
workflow_dispatch:
Expand Down Expand Up @@ -140,8 +140,8 @@ jobs:
echo "::notice::No new commits detected between rc and dev branches. Skipping PR creation."
echo "The branches rc and dev are already in sync."

rc-to-master-pr:
name: Create PR from RC to Master
rc-to-main-pr:
name: Create PR from RC to main
if: github.ref == 'refs/heads/rc' && github.repository == 'HyDE-Project/HyDE'
runs-on: ubuntu-latest
steps:
Expand All @@ -153,30 +153,30 @@ jobs:
- name: Generate commit history and schedule
id: generate-commits
run: |
chmod +x .github/scripts/promote_to_master.sh
bash .github/scripts/promote_to_master.sh
chmod +x .github/scripts/promote_to_main.sh
bash .github/scripts/promote_to_main.sh

# Check if there are any commits between master and rc
# Check if there are any commits between main and rc
- name: Check for commits between branches
id: check-commits
run: |
# Fetch master branch to make sure it exists locally
git fetch origin master:master || true
# Fetch main branch to make sure it exists locally
git fetch origin main:main || true

# We're already on rc branch since the job runs when rc is pushed
# Compare rc to master to see if there are any differences
if git rev-parse --verify master >/dev/null 2>&1; then
COMMIT_COUNT=$(git rev-list --count master..rc)
# Compare rc to main to see if there are any differences
if git rev-parse --verify main >/dev/null 2>&1; then
COMMIT_COUNT=$(git rev-list --count main..rc)
echo "commit_count=$COMMIT_COUNT" >> $GITHUB_OUTPUT
if [ "$COMMIT_COUNT" -gt 0 ]; then
echo "Detected $COMMIT_COUNT commit(s) between master and rc"
echo "Detected $COMMIT_COUNT commit(s) between main and rc"
echo "has_commits=true" >> $GITHUB_OUTPUT
else
echo "No commits detected between master and rc"
echo "No commits detected between main and rc"
echo "has_commits=false" >> $GITHUB_OUTPUT
fi
else
echo "Master branch doesn't exist yet. Assuming changes need to be propagated."
echo "main branch doesn't exist yet. Assuming changes need to be propagated."
echo "commit_count=999" >> $GITHUB_OUTPUT # Use a high number to indicate there are changes
echo "has_commits=true" >> $GITHUB_OUTPUT
fi
Expand All @@ -197,7 +197,7 @@ jobs:
script: |
const { repo, owner } = context.repo;
const prBranch = "rc";
const prTitle = "chore: Release - rc → master";
const prTitle = "chore: Release - rc → main";
const prBody = process.env.PR_BODY;

// Retry helper function
Expand All @@ -224,7 +224,7 @@ jobs:
owner,
repo,
head: `${owner}:${prBranch}`,
base: 'master',
base: 'main',
state: 'open'
});
});
Expand Down Expand Up @@ -252,14 +252,14 @@ jobs:
title: prTitle,
body: prBody,
head: prBranch,
base: 'master'
base: 'main'
});
});
console.log(`PR created: ${result.data.html_url}`);
} catch (error) {
console.log(`All attempts to create PR failed: ${error.message}`);
// As a fallback, output command for manual PR creation
console.log(`To create the PR manually, visit: https://github.com/${owner}/${repo}/compare/master...${prBranch}`);
console.log(`To create the PR manually, visit: https://github.com/${owner}/${repo}/compare/main...${prBranch}`);
throw error;
}
}
Expand All @@ -268,12 +268,12 @@ jobs:
- name: No Commits Message
if: steps.check-commits.outputs.has_commits == 'false'
run: |
echo "::notice::No new commits detected between master and rc branches. Skipping PR creation."
echo "The branches master and rc are already in sync."
echo "::notice::No new commits detected between main and rc branches. Skipping PR creation."
echo "The branches main and rc are already in sync."

release:
name: Quarterly Snapshot Release
if: github.ref == 'refs/heads/master' && github.repository == 'HyDE-Project/HyDE'
if: github.ref == 'refs/heads/main' && github.repository == 'HyDE-Project/HyDE'
runs-on: ubuntu-latest
steps:
- uses: googleapis/release-please-action@v3
Expand All @@ -284,7 +284,7 @@ jobs:
package-name: hyde
command: github-release
token: ${{ secrets.GITHUB_TOKEN }}
default-branch: master
default-branch: main
changelog-types: |
[
{"type":"feat","section":"Features","hidden":false},
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/refresh-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ jobs:
VERSION_TAG="$YEAR.$MONTH.$Q"
git commit --allow-empty -m "release: trigger quarterly refresh $VERSION_TAG"
git tag -a "$VERSION_TAG" -m "Quarterly release $VERSION_TAG"
git push origin HEAD:master
git push origin HEAD:main
git push origin "$VERSION_TAG"

- name: Provide feedback
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/warn-master-pr.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
name: Warn Master Branch PR
name: Warn Main Branch PR

on:
pull_request_target:
types: [opened, reopened, synchronize]

jobs:
warn-master-branch-pr:
name: Warn about PR targeting master branch
warn-main-branch-pr:
name: Warn about PR targeting main branch
runs-on: ubuntu-latest
permissions:
issues: write
Expand All @@ -27,7 +27,7 @@ jobs:
console.log('=== END DEBUG ===');

- name: Add warning comment
if: github.event.pull_request.base.ref == 'master'
if: github.event.pull_request.base.ref == 'main'
uses: actions/github-script@v6
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
Expand All @@ -53,15 +53,15 @@ jobs:

const botComment = comments.data.find(comment =>
comment.user.login === 'github-actions[bot]' &&
comment.body.includes('⚠️ Warning: PR targeting master branch')
comment.body.includes('⚠️ Warning: PR targeting main branch')
);

if (!botComment) {
await github.rest.issues.createComment({
owner,
repo,
issue_number,
body: "⚠️ **Warning: PR targeting master branch detected!**\n\n**This PR is targeting `master` but should target `dev` instead.**\n\nAccording to our [Quarterly Release Policy](https://github.com/HyDE-Project/HyDE/blob/master/RELEASE_POLICY.md):\n\n- **All pull requests must be submitted to the `dev` branch**\n- Changes go through `dev` first for testing before being merged to `master` during quarterly release windows (1st & 3rd Fridays)\n- **PRs to `master` are only allowed for emergencies**\n\n**Required Action:**\n1. **Change the base branch from `master` to `dev`**\n2. Follow the [pull request template](https://github.com/HyDE-Project/HyDE/blob/master/.github/PULL_REQUEST_TEMPLATE.md)\n\n**If this is an emergency fix, please add a comment explaining why it needs to target `master` directly.**\n\n---\n*This is an automated message enforcing our quarterly release workflow.*"
body: "⚠️ **Warning: PR targeting main branch detected!**\n\n**This PR is targeting `main` but should target `dev` instead.**\n\nAccording to our [Quarterly Release Policy](https://github.com/HyDE-Project/HyDE/blob/main/RELEASE_POLICY.md):\n\n- **All pull requests must be submitted to the `dev` branch**\n- Changes go through `dev` first for testing before being merged to `main` during quarterly release windows (1st & 3rd Fridays)\n- **PRs to `main` are only allowed for emergencies**\n\n**Required Action:**\n1. **Change the base branch from `main` to `dev`**\n2. Follow the [pull request template](https://github.com/HyDE-Project/HyDE/blob/main/.github/PULL_REQUEST_TEMPLATE.md)\n\n**If this is an emergency fix, please add a comment explaining why it needs to target `main` directly.**\n\n---\n*This is an automated message enforcing our quarterly release workflow.*"
});
console.log('Warning comment added to PR #' + issue_number);
} else {
Expand Down
1 change: 1 addition & 0 deletions Configs/.config/hypr/windowrules.conf
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@ windowrule = float true,match:title ^(Friends List)$ # Steam Friends List
windowrule = float true,match:title ^(Steam Settings)$ # Steam Settings
windowrule = float true,match:initial_title ^(Image Editor)$,match:class ^(blender)$ # Blender Render
windowrule = size (monitor_w*0.5) (monitor_h*0.5),match:initial_title ^(Image Editor)$,match:class ^(blender)$
windowrule = float true, match:initial_title ^(Ghidra: NO ACTIVE PROJECT) #Ghidra Project manager

# workaround for jetbrains IDEs dropdowns/popups cause flickering
windowrule = no_initial_focus true,match:class ^(.*jetbrains.*)$,match:title ^(win[0-9]+)$
Expand Down
Loading