Skip to content

Commit

Permalink
first commit
Browse files Browse the repository at this point in the history
  • Loading branch information
chaeya committed Jul 10, 2024
0 parents commit d933376
Show file tree
Hide file tree
Showing 136 changed files with 960 additions and 0 deletions.
55 changes: 55 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
name: Build and Release Debian Package

on:
push:
tags:
- "v*"

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Checkout source code
uses: actions/checkout@v4

- name: Build Debian Package
uses: jtdor/build-deb-action@v1
env:
DEB_BUILD_OPTIONS: noautodbgsym
with:
docker-image: ubuntu:24.04
buildpackage-opts: --build=binary --no-sign
# When change deb package name as git rev id
# before-build-hook: debchange --controlmaint --local="+ci${{ github.run_id }}~git$(git rev-parse --short HEAD)" "CI build"
before-build-hook: apt-get install -y devscripts equivs && mk-build-deps --install --remove debian/control
extra-build-deps: devscripts git equivs debhelper build-essential
host-arch: amd64
artifacts-dir: debian/artifacts

- name: Upload Debian Package
uses: actions/upload-artifact@v2
with:
name: debian-package
path: debian/artifacts/*.deb

release:
needs: build
runs-on: ubuntu-latest

steps:

- name: Download build artifacts
uses: actions/download-artifact@v2
with:
name: debian-package
path: .

- run: ls -R .

- name: Create GitHub Release
uses: softprops/action-gh-release@v1
with:
files: ./*.deb
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
674 changes: 674 additions & 0 deletions LICENSE

Large diffs are not rendered by default.

36 changes: 36 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# Grub Theme

## Installation

### Ubuntu, Debian, LinuxMint...

#### Prerequisites
Make sure you have the necessary dependencies installed:

```
sudo apt-get update
sudo apt-get install grub2-common
```

#### Download and Install
Download the latest .deb package from the releases page.
Install the package using dpkg:
```
sudo dpkg -i grub2-theme-dark*.deb
```

### Uninstallation
To remove the theme, run:

```
sudo apt-get remove grub2-theme-dark
```

## Contributing
Contributions are welcome! Please fork the repository and submit a pull request.

## License
This project is licensed under the GPL-3.0 license. See the LICENSE file for details.

## Contact
For any issues or questions, please open an issue on GitHub or visit to us at hamonikr.org.
5 changes: 5 additions & 0 deletions debian/changelog
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
grub2-theme-dark (1.0.0) stable; urgency=medium

* Release for HamoniKR paektu

-- HamoniKR <pkg@hamonikr.org> Wed, 10 Jul 2024 19:58:37 +0900
1 change: 1 addition & 0 deletions debian/compat
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
10
16 changes: 16 additions & 0 deletions debian/control
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
Source: grub2-theme-dark
Section: utils
Priority: optional
Maintainer: Kevin Kim <root@hamonikr.org>
Build-Depends: debhelper (>= 9)
Standards-Version: 3.9.5

Package: grub2-theme-dark
Architecture: all
Pre-Depends:
Depends:
Replaces:
Description: Grub2 Theme for HamoniKR
HamoniKR boot loader theme


18 changes: 18 additions & 0 deletions debian/copyright
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
Source: https://github.com/hamonikr/grub2-theme-kumkang

Files: *
Copyright: 2019-2020 HamoniKR <pkg@hamonikr.org>
License: GPL-3+
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.
.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
.
On Debian systems, the complete text of the GNU General
Public License can be found in `/usr/share/common-licenses/GPL'
2 changes: 2 additions & 0 deletions debian/install
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
etc/default/grub.d/90_hamonikr.cfg
usr/share/grub/themes/hamonikr-dark
21 changes: 21 additions & 0 deletions debian/postinst
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
#!/bin/sh

set -e

case "$1" in
configure)
if which update-grub2 > /dev/null 2>&1
then
LC_ALL=C update-grub2 || echo "Could not update grub, skipping."
fi
;;

abort-upgrade|abort-remove|abort-deconfigure)

;;

*)
echo "postinst called with unknown argument \`$1'" >&2
;;
esac

18 changes: 18 additions & 0 deletions debian/prerm
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
#!/bin/sh

set -e

case "$1" in
remove)
# Always remove this file when removing the package
# even if we're not purged. This file would break update-grub2
# if the package wasn't installed.
rm -f /etc/default/grub.d/90_hamonikr.cfg || echo "Could not remove 90_hamonikr.cfg, skipping."
if which update-grub2 > /dev/null 2>&1
then
LC_ALL=C update-grub2 || echo "Could not update grub, skipping."
fi
;;
esac

exit 0
7 changes: 7 additions & 0 deletions debian/rules
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#!/usr/bin/make -f

%:
dh ${@}

override_dh_builddeb:
dh_builddeb -- -Zxz -z9
1 change: 1 addition & 0 deletions debian/source/format
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
3.0 (native)
5 changes: 5 additions & 0 deletions etc/default/grub.d/90_hamonikr.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#! /bin/sh
set -e

GRUB_THEME="/usr/share/grub/themes/hamonikr-dark/theme.txt"

30 changes: 30 additions & 0 deletions get_resolution.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
#!/usr/bin/env bash

# grub-theme-hamonikr
# grub theme for HamoniKR-ME (>= 1.4)
# Copyright (C) 2019 Kevin Kim (root@hamonikr.org)
# - 사용자 해상도 자동 감지 후 테마 적용
# - 와이드 스크린의 경우 자동으로 비율을 계산
# - 한글 폰트로 grub 테마 제작
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.

# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.

# You should have received a copy of the GNU General Public License
# along with this program. If not, see <https://www.gnu.org/licenses/>.

## The location of the file with the resolutions
RESOLUTIONS="./resolutions.txt"

# xrandr -q | grep -Po 'current\s*\K\d+\s*x\s*\d+' | sed 's/ *x */ /' |
xrandr --current | grep "*" | head -n 1 | sed 's/ *x */ /' | awk -F" " '{print $1 " " $2}' |
while read x y; do
grep "$x" "$RESOLUTIONS" | grep "$y" | awk -F" " '{print $2}';
done
26 changes: 26 additions & 0 deletions resolutions.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
VGA 4:3 640 480 00.02 n/a
SVGA 4:3 800 600 00.17 01.03
WSVGA ~17:10 1024 600 00.31 02.25
XGA 4:3 1024 768 05.53 18.69
XGA+ 4:3 1152 864 00.87 01.55
WXGA 16:9 1280 720 01.51 01.54
WXGA 5:3 1280 768 n/a 01.54
WXGA 16:10 1280 800 04.25 12.97
SXGA– (UVGA) 4:3 1280 960 00.72 00.72
SXGA 5:4 1280 1024 10.66 07.49
HD ~16:9 1360 768 02.36 02.28
HD ~16:9 1366 768 17.19 19.14
SXGA+ 4:3 1400 1050 00.18 n/a
WXGA+ 16:10 1440 900 07.60 06.61
HD+ 16:9 1600 900 06.82 03.82
UXGA 4:3 1600 1200 00.53 n/a
WSXGA+ 16:10 1680 1050 10.26 03.66
FHD 16:9 1920 1080 25.04 05.09
WUXGA 16:10 1920 1200 03.65 01.11
QWXGA 16:9 2048 1152 00.13 n/a
WQHD 16:9 2560 1440 00.72 00.36
WQXGA 16:10 2560 1600 00.19 n/a
3:4 768 1024 n/a 01.93
16:9 1093 614 n/a 00.63
~16:9 1311 737 n/a 00.35
Other 01.29 07.25
Binary file not shown.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added usr/share/grub/themes/hamonikr-dark/hackb_18.pf2
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added usr/share/grub/themes/hamonikr-dark/icons/edit.png
Binary file added usr/share/grub/themes/hamonikr-dark/icons/efi.png
Binary file added usr/share/grub/themes/hamonikr-dark/icons/help.png
Binary file added usr/share/grub/themes/hamonikr-dark/icons/kbd.png
Binary file added usr/share/grub/themes/hamonikr-dark/icons/lfs.png
Binary file added usr/share/grub/themes/hamonikr-dark/icons/mx.png
Binary file added usr/share/grub/themes/hamonikr-dark/icons/nixos.png
Binary file added usr/share/grub/themes/hamonikr-dark/icons/pop.png
Binary file added usr/share/grub/themes/hamonikr-dark/icons/red.png
Binary file added usr/share/grub/themes/hamonikr-dark/icons/type.png
Binary file added usr/share/grub/themes/hamonikr-dark/icons/tz.png
Binary file added usr/share/grub/themes/hamonikr-dark/icons/unset.png
Binary file added usr/share/grub/themes/hamonikr-dark/menu_bkg_c.png
Binary file added usr/share/grub/themes/hamonikr-dark/menu_bkg_e.png
Binary file added usr/share/grub/themes/hamonikr-dark/menu_bkg_n.png
Binary file added usr/share/grub/themes/hamonikr-dark/menu_bkg_ne.png
Binary file added usr/share/grub/themes/hamonikr-dark/menu_bkg_nw.png
Binary file added usr/share/grub/themes/hamonikr-dark/menu_bkg_s.png
Binary file added usr/share/grub/themes/hamonikr-dark/menu_bkg_se.png
Binary file added usr/share/grub/themes/hamonikr-dark/menu_bkg_sw.png
Binary file added usr/share/grub/themes/hamonikr-dark/menu_bkg_w.png
Binary file added usr/share/grub/themes/hamonikr-dark/select_c.png
Binary file added usr/share/grub/themes/hamonikr-dark/select_e.png
Binary file added usr/share/grub/themes/hamonikr-dark/select_w.png
Binary file added usr/share/grub/themes/hamonikr-dark/slider_c.png
Binary file added usr/share/grub/themes/hamonikr-dark/slider_n.png
Binary file added usr/share/grub/themes/hamonikr-dark/slider_s.png
45 changes: 45 additions & 0 deletions usr/share/grub/themes/hamonikr-dark/theme.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# GRUB theme

desktop-image: "background.png"
title-text: ""
terminal-font: "D2Coding Nerd Font Regular 20"
terminal-left: "0"
terminal-top: "0"
terminal-width: "100%"
terminal-height: "100%"
terminal-border: "0"

+ boot_menu {
menu_pixmap_style = "boot_menu_*.png"
left = 10%
width = 45%
top = 30%
height = 40%
item_font = "Monaco Regular 18"
item_color = "#6b6b6b"
selected_item_font = "Monaco Regular 18"
selected_item_color = "#ffffff"
icon_width = 32
icon_height = 32
item_icon_space = 20
item_height = 36
item_padding = 5
item_spacing = 10
selected_item_pixmap_style = "select_*.png"
scrollbar = true
scrollbar_width = 10
scrollbar_thumb = "slider_*.png"
}

+ progress_bar {
id = "__timeout__"
left = 10%
width = 45%
top = 75%
height = 20
text = ""
text_color = "#ffffff"
font = "D2Coding Nerd Font Regular 20"
bar_style = "progress_bar_*.png"
highlight_style = "progress_highlight_*.png"
}

0 comments on commit d933376

Please sign in to comment.