Skip to content

feat: enhance clipboard history with fuzzy search and paste simulation #9

feat: enhance clipboard history with fuzzy search and paste simulation

feat: enhance clipboard history with fuzzy search and paste simulation #9

Workflow file for this run

name: Release & AUR Update
on:
push:
tags:
- "v*.*.*"
permissions:
contents: write
jobs:
release:
runs-on: ubuntu-latest
environment: main
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Extract version
id: get_version
run: echo "version=${GITHUB_REF#refs/tags/v}" >> $GITHUB_OUTPUT
- name: Generate release description
id: release_description
run: |
cat > release_body.md << EOF
# Clipse GUI v${{ steps.get_version.outputs.version }}
Clipse GUI is a graphical interface for the Clipse clipboard manager.
## 📋 Key Features
- Easily manage clipboard history
- Powerful search capabilities
- Intuitive user interface
- Customizable settings
## 🚀 Installation
### Arch Linux
```bash
yay -S clipse-gui
```
### Manual Installation
See [installation instructions](https://github.com/yourusername/clipse-gui#installation) for details.
## 🔄 Changelog
See below for a full list of changes in this release.
EOF
DESCRIPTION=$(cat release_body.md)
# This handles multiline strings correctly in GitHub Actions
echo "description<<EOF" >> $GITHUB_OUTPUT
echo "$DESCRIPTION" >> $GITHUB_OUTPUT
echo "EOF" >> $GITHUB_OUTPUT
- name: Create GitHub Release
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ github.ref }}
name: "Release v${{ steps.get_version.outputs.version }}"
body: ${{ steps.release_description.outputs.description }}
generate_release_notes: true
draft: false
prerelease: false
update-aur:
runs-on: ubuntu-latest
environment: main
needs: release
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Extract version
id: get_version
run: echo "version=${GITHUB_REF#refs/tags/v}" >> $GITHUB_OUTPUT
- name: Set up Git
run: |
git config --global user.name "GitHub Actions"
git config --global user.email "[email protected]"
- name: Set up SSH
env:
AUR_SSH_KEY: ${{ secrets.AUR_SSH_KEY }}
run: |
mkdir -p ~/.ssh
echo "$AUR_SSH_KEY" > ~/.ssh/id_rsa
chmod 600 ~/.ssh/id_rsa
ssh-keyscan -t rsa aur.archlinux.org >> ~/.ssh/known_hosts
- name: Clone AUR repo
run: |
git clone ssh://[email protected]/clipse-gui.git aur-repo
- name: Update PKGBUILD
run: |
cd aur-repo
git config --global --add safe.directory "$(pwd)"
sed -i "s/^pkgver=.*/pkgver=${{ steps.get_version.outputs.version }}/" PKGBUILD
sed -i "s/^pkgrel=.*/pkgrel=1/" PKGBUILD
- name: Setup Arch environment for AUR operations
uses: archlinux/arch-builder-action@master
with:
path: aur-repo
command: |
pacman -Syu --noconfirm
pacman -S --noconfirm base-devel
updpkgsums
makepkg --printsrcinfo > .SRCINFO
ls -la
- name: Commit and push AUR update
run: |
cd aur-repo
git add PKGBUILD .SRCINFO
git commit -m "Update to v${{ steps.get_version.outputs.version }}"
git push