Skip to content

Commit

Permalink
style tweaks; add tab hotkey; other fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Kosette committed Oct 12, 2024
1 parent cff24b4 commit 2882b04
Show file tree
Hide file tree
Showing 10 changed files with 187 additions and 113 deletions.
34 changes: 16 additions & 18 deletions .github/workflows/build_linux.yml
Original file line number Diff line number Diff line change
@@ -1,24 +1,22 @@
name: Linux CI
on:
workflow_dispatch:
push:
branches:
- "main"
paths-ignore:
- "docs/**"
- "**/.gitignore"
- "**/.dockerignore"
- LICENSE
- "**/*.md"
pull_request:
branches:
- "main"
paths-ignore:
- "docs/**"
- "**/.gitignore"
- "**/.dockerignore"
- LICENSE
- "**/*.md"
# push:
# branches:
# - "dev"
# paths-ignore:
# - "docs/**"
# - ".gitignore"
# - LICENSE
# - "*.md"
# pull_request:
# branches:
# - "dev"
# paths-ignore:
# - "docs/**"
# - ".gitignore"
# - LICENSE
# - "*.md"

jobs:
build:
Expand Down
54 changes: 30 additions & 24 deletions .github/workflows/build_release.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,14 @@
name: CI Passing
on:
push:
tags:
- v*
workflow_dispatch:
# push:
# branches:
# - "dev"
# paths-ignore:
# - "docs/**"
# - "*.md"
# - LICENSE
# - .gitignore

env:
CARGO_TERM_COLOR: always
Expand All @@ -23,7 +29,7 @@ jobs:
os: ubuntu-latest
target: arm64
# x86_64-windows-gnu
- arch: x86_64-windows-gnu
- arch: ucrt-x86_64-windows-gnu
os: windows-latest
target: amd64

Expand All @@ -39,19 +45,19 @@ jobs:
with:
update: true
release: false
msystem: MINGW64
msystem: UCRT64
install: >-
mingw-w64-x86_64-pkgconf
mingw-w64-x86_64-gcc
mingw-w64-x86_64-mpv
mingw-w64-x86_64-libadwaita
mingw-w64-x86_64-gstreamer
mingw-w64-x86_64-glib2
mingw-w64-x86_64-gst-plugins-base
mingw-w64-x86_64-gst-plugins-good
mingw-w64-x86_64-gst-plugins-bad
mingw-w64-x86_64-gst-plugins-ugly
mingw-w64-x86_64-gst-libav
mingw-w64-ucrt-x86_64-pkgconf
mingw-w64-ucrt-x86_64-gcc
mingw-w64-ucrt-x86_64-mpv
mingw-w64-ucrt-x86_64-libadwaita
mingw-w64-ucrt-x86_64-gstreamer
mingw-w64-ucrt-x86_64-glib2
mingw-w64-ucrt-x86_64-gst-plugins-base
mingw-w64-ucrt-x86_64-gst-plugins-good
mingw-w64-ucrt-x86_64-gst-plugins-bad
mingw-w64-ucrt-x86_64-gst-plugins-ugly
mingw-w64-ucrt-x86_64-gst-libav
curl
- name: Build tsukimi-${{ matrix.arch }}
Expand All @@ -71,22 +77,22 @@ jobs:
cp $GITHUB_WORKSPACE/target/release/tsukimi.exe bin/
cp /mingw64/bin/gdbus.exe bin/
cp -r /mingw64/lib/gdk-pixbuf-2.0 lib/
cp -r /ucrt64/lib/gdk-pixbuf-2.0 lib/
find lib/gdk-pixbuf-2.0/2.10.0/loaders -type f ! \( -name "*-svg.dll" -o -name "*-png.dll" -o -name "*-jpeg.dll" \) -exec rm -f "{}" \;
cp -r /mingw64/lib/gio lib/
cp -r /ucrt64/lib/gio lib/
cp -r /mingw64/lib/gstreamer-1.0 lib/ && find lib/gstreamer-1.0 -type f ! -name "*.dll" -exec rm -f "{}" \;
cp -r /ucrt64/lib/gstreamer-1.0 lib/ && find lib/gstreamer-1.0 -type f ! -name "*.dll" -exec rm -f "{}" \;
cp -r $GITHUB_WORKSPACE/i18n/locale share/
cp -r /mingw64/share/glib-2.0 share/
cp -r /ucrt64/share/glib-2.0 share/
find share/glib-2.0/* -maxdepth 0 -type d ! -name "*schemas*" -exec rm -rf "{}" \;
mv $GITHUB_WORKSPACE/moe.tsuna.tsukimi.gschema.xml share/glib-2.0/schemas/
glib-compile-schemas.exe share/glib-2.0/schemas/
find share/glib-2.0/ -type f ! -name "*.compiled" -exec rm -f "{}" \;
cp -r /mingw64/share/icons share/
cp -r /ucrt64/share/icons share/
cp $GITHUB_WORKSPACE/resources/ui/icons/tsukimi.png share/icons/
rm -rf share/icons/hicolor && rm -rf share/icons/AdwaitaLegacy && rm -rf share/icons/Adwaita/scalable && rm -rf share/icons/Adwaita/cursors
rm -rf share/icons/Adwaita/16x16 && rm -rf share/icons/Adwaita/symbolic-up-to-32
Expand All @@ -103,8 +109,8 @@ jobs:
libgstxingmux.dll libgsty4menc.dll libgstzbar.dll
cd $GITHUB_WORKSPACE/artifact/tsukimi-x86_64-windows-gnu
ldd bin/tsukimi.exe | grep '\/mingw64.*\.dll' -o | xargs -I{} cp -n "{}" bin/
find lib/ -type f -name "*.dll" -exec ldd "{}" \; | grep '\/mingw64.*\.dll' -o | xargs -I{} cp -n "{}" bin/
ldd bin/tsukimi.exe | grep '\/ucrt64.*\.dll' -o | xargs -I{} cp -n "{}" bin/
find lib/ -type f -name "*.dll" -exec ldd "{}" \; | grep '\/ucrt64.*\.dll' -o | xargs -I{} cp -n "{}" bin/
- name: Create NSIS installer
if: ${{ matrix.arch == 'x86_64-windows-gnu' }}
Expand Down Expand Up @@ -187,7 +193,7 @@ jobs:
- name: Get latest tag name
id: tag
run: echo "TAG_NAME=$(git describe --tags --abbrev=0)" >> $GITHUB_OUTPUT
run: echo "TAG_NAME=v$(date '+%Y-%m-%d-%H%M%S')" >> $GITHUB_OUTPUT

- name: Set prerelease variable
if: startsWith(github.ref, 'refs/tags/v') && endsWith(github.ref, '-alpha')
Expand Down
29 changes: 13 additions & 16 deletions .github/workflows/build_windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,20 @@ on:
workflow_dispatch:
push:
branches:
- "main"
- "dev"
paths-ignore:
- "docs/**"
- "**/.gitignore"
- "**/.dockerignore"
- ".gitignore"
- LICENSE
- "**/*.md"
pull_request:
branches:
- "main"
paths-ignore:
- "docs/**"
- "**/.gitignore"
- "**/.dockerignore"
- LICENSE
- "**/*.md"
- "*.md"
# pull_request:
# branches:
# - "dev"
# paths-ignore:
# - "docs/**"
# - ".gitignore"
# - LICENSE
# - "*.md"

env:
CARGO_TERM_COLOR: always
Expand All @@ -38,7 +36,6 @@ jobs:
# env: x86_64
- arch: ucrt64-x86_64-windows-gnu
os: windows-latest
target: x86_64-pc-windows-gnu
msystem: ucrt64
env: ucrt-x86_64

Expand Down Expand Up @@ -70,7 +67,7 @@ jobs:
mingw-w64-${{ matrix.env }}-gst-libav
curl
- name: Build tsukimi-${{ matrix.target }}
- name: Build tsukimi-${{ matrix.arch }}
if: ${{ !startsWith(github.ref, 'refs/tags/') }}
shell: msys2 {0}
run: |
Expand Down Expand Up @@ -151,8 +148,8 @@ jobs:
with:
name: tsukimi-${{matrix.arch}}
path: |
artifact/*.exe
artifact/*.7z
artifact/*.exe
artifact/*.sha512sum
compression-level: 0
retention-days: 3
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@
/i18n
/.idea
/backup
/.cargo
Loading

0 comments on commit 2882b04

Please sign in to comment.