GitHubのミラーです
https://github.com/FascodeNet/alterlinux
Revision | 757fdb6738ea50da7ca54c810bd44be0800863b3 (tree) |
---|---|
Time | 2020-03-02 18:34:49 |
Author | hayao <shun819.mail@gmai...> |
Commiter | hayao |
Merge branch 'dev-stable'
@@ -12,4 +12,7 @@ | ||
12 | 12 | pkg/ |
13 | 13 | src/ |
14 | 14 | out/ |
15 | -work/ | |
\ No newline at end of file | ||
15 | +work/ | |
16 | + | |
17 | +airootfs/etc/skel/.config/xfce4/xfconf/xfce-perchannel-xml/xfce4-notifyd.xml | |
18 | +airootfs/etc/skel/.config/xfce4/desktop/ |
@@ -0,0 +1,53 @@ | ||
1 | +BUILD_SCRIPT = build.sh | |
2 | + | |
3 | + | |
4 | +linux: | |
5 | + @sudo ./${BUILD_SCRIPT} -b -c "zstd" -p "alter" | |
6 | + @make cleanup | |
7 | + | |
8 | +ck : | |
9 | + @sudo ./${BUILD_SCRIPT} -b -c "zstd" -p "alter" -k ck | |
10 | + @make cleanup | |
11 | + | |
12 | +lts: | |
13 | + @sudo ./${BUILD_SCRIPT} -b -c "zstd" -p "alter" -k lts | |
14 | + @make cleanup | |
15 | + | |
16 | +lqx: | |
17 | + @sudo ./${BUILD_SCRIPT} -b -c "zstd" -p "alter" -k lqx | |
18 | + @make cleanup | |
19 | + | |
20 | +rt: | |
21 | + @sudo ./${BUILD_SCRIPT} -b -c "zstd" -p "alter" -k rt | |
22 | + @make cleanup | |
23 | + | |
24 | +zen: | |
25 | + @sudo ./${BUILD_SCRIPT} -b -c "zstd" -p "alter" -k zen | |
26 | + @make cleanup | |
27 | + | |
28 | +test-linux: | |
29 | + @sudo ./${BUILD_SCRIPT} -b -c "zstd" -p "alter" -t '-Xcompression-level 1' -x | |
30 | + @make cleanup | |
31 | + | |
32 | +test-ck: | |
33 | + @sudo ./${BUILD_SCRIPT} -b -c "zstd" -p "alter" -k ck -t '-Xcompression-level 1' -x | |
34 | + @make cleanup | |
35 | + | |
36 | +test-lts: | |
37 | + @sudo ./${BUILD_SCRIPT} -b -c "zstd" -p "alter" -k lts -t '-Xcompression-level 1' -x | |
38 | + @make cleanup | |
39 | + | |
40 | +test-lqx: | |
41 | + @sudo ./${BUILD_SCRIPT} -b -c "zstd" -p "alter" -k lqx -t '-Xcompression-level 1' -x | |
42 | + @make cleanup | |
43 | + | |
44 | +test-rt: | |
45 | + @sudo ./${BUILD_SCRIPT} -b -c "zstd" -p "alter" -k rt -t '-Xcompression-level 1' -x | |
46 | + @make cleanup | |
47 | + | |
48 | +test-zen: | |
49 | + @sudo ./${BUILD_SCRIPT} -b -c "zstd" -p "alter" -k zen -t '-Xcompression-level 1' -x | |
50 | + @make cleanup | |
51 | + | |
52 | +cleanup: | |
53 | + @sudo rm -rf ./work | |
\ No newline at end of file |
@@ -10,14 +10,18 @@ | ||
10 | 10 | | [日本語](README_jp.md) | [English](README.md) | |
11 | 11 | |:-----:|:-----:| |
12 | 12 | |
13 | -| [Stable](https://github.com/SereneTeam/alterlinux/tree/master) | [Unstable](https://github.com/SereneTeam/alterlinux/tree/dev-stable) | [Develop](https://github.com/SereneTeam/alterlinux/tree/dev) | | |
14 | -|:-----:|:-----:|:-----:| | |
15 | - | |
16 | 13 | ## Overview |
17 | 14 | |
18 | 15 | Alter Linux is a new OS developed based on Arch Linux. |
19 | 16 | Combining a sophisticated UI with Xfce4 and a package management tool complete with a GUI, anyone can easily use the latest OS at high speed. |
20 | 17 | |
18 | +## Branch | |
19 | +The main branches are: Other branches are temporary or used for specific purposes. | |
20 | + | |
21 | +| [Stable](https://github.com/SereneTeam/alterlinux/tree/master) | [dev-stable](https://github.com/SereneTeam/alterlinux/tree/dev-stable) | [dev](https://github.com/SereneTeam/alterlinux/tree/dev) | | |
22 | +|:-----:|:-----:|:-----:| | |
23 | +| Most stable. Bug fixes may be delayed. | It is updated regularly. Relatively stable, with the latest features and fixes. | Always updated. There may be many issues left. | | |
24 | + | |
21 | 25 | ## Repositories and software |
22 | 26 | |
23 | 27 | ### Repositories |
@@ -10,15 +10,19 @@ | ||
10 | 10 | | [日本語](README_jp.md) | [English](README.md) | |
11 | 11 | |:-----:|:-----:| |
12 | 12 | |
13 | -| [安定版](https://github.com/SereneTeam/alterlinux/tree/master) | [リリース候補](https://github.com/SereneTeam/alterlinux/tree/dev-stable) | [開発](https://github.com/SereneTeam/alterlinux/tree/dev) | | |
14 | -|:-----:|:-----:|:-----:| | |
15 | - | |
16 | 13 | ## 概要 |
17 | 14 | |
18 | 15 | Alter LinuxはArch Linuxをベースに開発されている新しいOSです。 |
19 | 16 | Xfce4による洗練されたUIとGUIで完結するパッケージ管理ツールを兼ね備え、誰でも簡単に高速で最新のOSを使用できます。 |
20 | - | |
21 | - ## リポジトリとソフトウェア | |
17 | + | |
18 | +## ブランチ | |
19 | +主要なブランチは以下のとおりです。これ以外のブランチは一時的なものや特定の用途で使われているものです。 | |
20 | + | |
21 | +| [安定版](https://github.com/SereneTeam/alterlinux/tree/master) | [リリース候補](https://github.com/SereneTeam/alterlinux/tree/dev-stable) | [開発](https://github.com/SereneTeam/alterlinux/tree/dev) | | |
22 | +|:-----:|:-----:|:-----:| | |
23 | +| 最も安定しています。バグの修正などは遅れる場合があります。 | 定期的に更新されます。比較的安定していて、最新の機能や修正を利用できます。 | 常に更新されます。問題が多数残っている場合があります。| | |
24 | + | |
25 | +## リポジトリとソフトウェア | |
22 | 26 | |
23 | 27 | ### リポジトリ |
24 | 28 | - [SereneTeam/alter-repo](https://github.com/SereneTeam/alter-repo) |
@@ -0,0 +1,35 @@ | ||
1 | +# | |
2 | +# [greeter] | |
3 | +# debug_mode = Greeter theme debug mode. | |
4 | +# detect_theme_errors = Provide an option to load a fallback theme when theme errors are detected. | |
5 | +# screensaver_timeout = Blank the screen after this many seconds of inactivity. | |
6 | +# secure_mode = Don't allow themes to make remote http requests. | |
7 | +# time_format = A moment.js format string so the greeter can generate localized time for display. | |
8 | +# time_language = Language to use when displaying the time or "auto" to use the system's language. | |
9 | +# webkit_theme = Webkit theme to use. | |
10 | +# | |
11 | +# NOTE: See moment.js documentation for format string options: http://momentjs.com/docs/#/displaying/format/ | |
12 | +# | |
13 | + | |
14 | +[greeter] | |
15 | +debug_mode = false | |
16 | +detect_theme_errors = true | |
17 | +screensaver_timeout = 300 | |
18 | +secure_mode = true | |
19 | +time_format = LT | |
20 | +time_language = auto | |
21 | +webkit_theme = alter | |
22 | + | |
23 | +# | |
24 | +# [branding] | |
25 | +# background_images = Path to directory that contains background images for use by themes. | |
26 | +# logo = Path to logo image for use by greeter themes. | |
27 | +# user_image = Default user image/avatar. This is used by themes for users that have no .face image. | |
28 | +# | |
29 | +# NOTE: Paths must be accessible to the lightdm system user account (so they cannot be anywhere in /home) | |
30 | +# | |
31 | + | |
32 | +[branding] | |
33 | +background_images = /usr/share/backgrounds | |
34 | +logo = /usr/share/pixmaps/archlinux-logo.svg | |
35 | +user_image = /usr/share/pixmaps/archlinux-user.svg |
@@ -1,7 +0,0 @@ | ||
1 | -[Greeter] | |
2 | -background=/usr/share/backgrounds/login.png | |
3 | -draw-user-backgrounds=false | |
4 | -draw-grid=false | |
5 | -theme-name=Materia-dark-compact | |
6 | -icon-theme-name=Paper | |
7 | -other-monitors-logo= |
@@ -1,11 +1,12 @@ | ||
1 | 1 | # |
2 | 2 | # ~/.bash_profile |
3 | 3 | # |
4 | - | |
4 | +<<DISABLED | |
5 | 5 | if [[ -f ~/.setup.sh ]]; then |
6 | 6 | bash ~/.setup.sh |
7 | 7 | rm ~/.setup.sh |
8 | 8 | fi |
9 | +DISABLED | |
9 | 10 | |
10 | 11 | [[ -f ~/.bashrc ]] && . ~/.bashrc |
11 | 12 | [[ -z $DISPLAY && $XDG_VTNR -eq 1 ]] && exec startx |
@@ -0,0 +1,5 @@ | ||
1 | +file:///home/alter/Pictures | |
2 | +file:///home/alter/Videos | |
3 | +file:///home/alter/Music | |
4 | +file:///home/alter/Downloads | |
5 | +file:///home/alter/Documents |
@@ -1,5 +1,5 @@ | ||
1 | -favorites=exo-terminal-emulator.desktop,exo-file-manager.desktop,exo-mail-reader.desktop,exo-web-browser.desktop | |
2 | -recent=xfce-display-settings.desktop,xfce-settings-manager.desktop,exo-file-manager.desktop,exo-terminal-emulator.desktop,exo-web-browser.desktop | |
1 | +favorites=chromium.desktop,thunderbird.desktop,vlc.desktop,leafpad.desktop,code-oss.desktop,xfce4-screenshooter.desktop | |
2 | +recent= | |
3 | 3 | button-title=Alter |
4 | 4 | button-icon=alter |
5 | 5 | button-single-row=false |
@@ -14,7 +14,7 @@ category-show-name=true | ||
14 | 14 | category-icon-size=1 |
15 | 15 | load-hierarchy=false |
16 | 16 | view-as-icons=false |
17 | -recent-items-max=10 | |
17 | +recent-items-max=0 | |
18 | 18 | favorites-in-recent=true |
19 | 19 | display-recent-default=false |
20 | 20 | position-search-alternate=true |
@@ -38,14 +38,14 @@ | ||
38 | 38 | <value type="int" value="1"/> |
39 | 39 | <value type="int" value="14"/> |
40 | 40 | </property> |
41 | - <property name="enter-opacity" type="uint" value="75"/> | |
42 | - <property name="leave-opacity" type="uint" value="75"/> | |
41 | + <property name="enter-opacity" type="uint" value="100"/> | |
42 | + <property name="leave-opacity" type="uint" value="100"/> | |
43 | 43 | <property name="background-style" type="uint" value="1"/> |
44 | 44 | <property name="background-rgba" type="array"> |
45 | 45 | <value type="double" value="0.000000"/> |
46 | 46 | <value type="double" value="0.000000"/> |
47 | 47 | <value type="double" value="0.000000"/> |
48 | - <value type="double" value="1.000000"/> | |
48 | + <value type="double" value="0.000000"/> | |
49 | 49 | </property> |
50 | 50 | </property> |
51 | 51 | <property name="panel-3" type="empty"> |
@@ -53,8 +53,8 @@ | ||
53 | 53 | <property name="size" type="uint" value="35"/> |
54 | 54 | <property name="length" type="uint" value="10"/> |
55 | 55 | <property name="position-locked" type="bool" value="true"/> |
56 | - <property name="enter-opacity" type="uint" value="75"/> | |
57 | - <property name="leave-opacity" type="uint" value="75"/> | |
56 | + <property name="enter-opacity" type="uint" value="100"/> | |
57 | + <property name="leave-opacity" type="uint" value="100"/> | |
58 | 58 | <property name="plugin-ids" type="array"> |
59 | 59 | <value type="int" value="11"/> |
60 | 60 | <value type="int" value="13"/> |
@@ -65,7 +65,7 @@ | ||
65 | 65 | <value type="double" value="0.000000"/> |
66 | 66 | <value type="double" value="0.000000"/> |
67 | 67 | <value type="double" value="0.000000"/> |
68 | - <value type="double" value="1.000000"/> | |
68 | + <value type="double" value="0.000000"/> | |
69 | 69 | </property> |
70 | 70 | </property> |
71 | 71 | <property name="panel-4" type="empty"> |
@@ -86,10 +86,10 @@ | ||
86 | 86 | <value type="double" value="0.000000"/> |
87 | 87 | <value type="double" value="0.000000"/> |
88 | 88 | <value type="double" value="0.000000"/> |
89 | - <value type="double" value="1.000000"/> | |
89 | + <value type="double" value="0.000000"/> | |
90 | 90 | </property> |
91 | - <property name="enter-opacity" type="uint" value="75"/> | |
92 | - <property name="leave-opacity" type="uint" value="75"/> | |
91 | + <property name="enter-opacity" type="uint" value="100"/> | |
92 | + <property name="leave-opacity" type="uint" value="100"/> | |
93 | 93 | </property> |
94 | 94 | <property name="panel-5" type="empty"> |
95 | 95 | <property name="position" type="string" value="p=8;x=98;y=949"/> |
@@ -135,7 +135,9 @@ | ||
135 | 135 | <property name="style" type="uint" value="0"/> |
136 | 136 | <property name="expand" type="bool" value="true"/> |
137 | 137 | </property> |
138 | - <property name="plugin-13" type="string" value="clock"/> | |
138 | + <property name="plugin-13" type="string" value="clock"> | |
139 | + <property name="digital-format" type="string" value="%m/%d %a %l:%M:%S"/> | |
140 | + </property> | |
139 | 141 | <property name="plugin-14" type="string" value="separator"> |
140 | 142 | <property name="expand" type="bool" value="true"/> |
141 | 143 | <property name="style" type="uint" value="0"/> |
@@ -151,6 +153,7 @@ | ||
151 | 153 | </property> |
152 | 154 | <property name="plugin-23" type="string" value="systray"> |
153 | 155 | <property name="names-ordered" type="array"> |
156 | + <value type="string" value="networkmanager applet"/> | |
154 | 157 | <value type="string" value="thunar"/> |
155 | 158 | <value type="string" value="pamac-tray"/> |
156 | 159 | <value type="string" value="blueman-tray"/> |
@@ -0,0 +1,35 @@ | ||
1 | +#!/usr/bin/env bash | |
2 | + | |
3 | +# Creating a xdg | |
4 | +LANG=C | |
5 | +xdg-user-dirs-update | |
6 | + | |
7 | +HOME="~" | |
8 | +if [[ -f ${HOME}/.config/user-dirs.dirs ]]; then | |
9 | + source ${HOME}/.config/user-dirs.dirs | |
10 | + | |
11 | + # Add pictures to bookmark | |
12 | + echo -n "file://" >> ${HOME}/.config/gtk-3.0/bookmarks | |
13 | + echo -n "${XDG_PICTURES_DIR}" >> ${HOME}/.config/gtk-3.0/bookmarks | |
14 | + echo -ne "\n" >> ${HOME}/.config/gtk-3.0/bookmarks | |
15 | + | |
16 | + # Add videos to bookmark | |
17 | + echo -n "file://" >> ${HOME}/.config/gtk-3.0/bookmarks | |
18 | + echo -n "${XDG_VIDEOS_DIR}" >> ${HOME}/.config/gtk-3.0/bookmarks | |
19 | + echo -ne "\n" >> ${HOME}/.config/gtk-3.0/bookmarks | |
20 | + | |
21 | + # Add music to bookmark | |
22 | + echo -n "file://" >> ${HOME}/.config/gtk-3.0/bookmarks | |
23 | + echo -n "${XDG_VIDEOS_DIR}" >> ${HOME}/.config/gtk-3.0/bookmarks | |
24 | + echo -ne "\n" >> ${HOME}/.config/gtk-3.0/bookmarks | |
25 | + | |
26 | + # Add downloads to bookmark | |
27 | + echo -n "file://" >> ${HOME}/.config/gtk-3.0/bookmarks | |
28 | + echo -n "${XDG_DOWNLOAD_DIR}" >> ${HOME}/.config/gtk-3.0/bookmarks | |
29 | + echo -ne "\n" >> ${HOME}/.config/gtk-3.0/bookmarks | |
30 | + | |
31 | + # Add documents to bookmark | |
32 | + echo -n "file://" >> ${HOME}/.config/gtk-3.0/bookmarks | |
33 | + echo -n "${XDG_DOCUMENTS_DIR}" >> ${HOME}/.config/gtk-3.0/bookmarks | |
34 | + echo -ne "\n" >> ${HOME}/.config/gtk-3.0/bookmarks | |
35 | +fi | |
\ No newline at end of file |
@@ -2,7 +2,7 @@ | ||
2 | 2 | |
3 | 3 | set -e -u |
4 | 4 | |
5 | -# デフォルト値 | |
5 | +# Default value | |
6 | 6 | password=alter |
7 | 7 | boot_splash=false |
8 | 8 | kernel= |
@@ -17,6 +17,7 @@ while getopts 'p:bt:k:' arg; do | ||
17 | 17 | b) boot_splash=true ;; |
18 | 18 | t) theme_name="${OPTARG}" ;; |
19 | 19 | k) kernel="${OPTARG}" ;; |
20 | + x) set -x ;; | |
20 | 21 | esac |
21 | 22 | done |
22 | 23 |
@@ -40,16 +41,37 @@ LC_ALL=C xdg-user-dirs-update | ||
40 | 41 | LANG=C xdg-user-dirs-update |
41 | 42 | echo -e "${password}\n${password}" | passwd root |
42 | 43 | |
44 | +# Allow sudo group to run sudo | |
45 | +sed -i 's/^#\s*\(%sudo\s\+ALL=(ALL)\s\+ALL\)/\1/' /etc/sudoers | |
43 | 46 | |
44 | 47 | # Create alter user. |
45 | -useradd -m -s /bin/bash alter | |
46 | -groupadd sudo | |
47 | -usermod -G sudo alter | |
48 | -sed -i 's/^#\s*\(%sudo\s\+ALL=(ALL)\s\+ALL\)/\1/' /etc/sudoers | |
49 | -cp -aT /etc/skel/ /home/alter/ | |
50 | -chmod 700 -R /home/alter | |
51 | -chown alter:alter -R /home/alter | |
52 | -echo -e "${password}\n${password}" | passwd alter | |
48 | +# create_user -u <username> -p <password> | |
49 | +function create_user () { | |
50 | + local _password | |
51 | + local _username | |
52 | + _password=${password} | |
53 | + _username=alter | |
54 | + | |
55 | + # Option analysis | |
56 | + while getopts 'p:u:' arg; do | |
57 | + case "${arg}" in | |
58 | + p) _password="${OPTARG}" ;; | |
59 | + u) _username="${OPTARG}" ;; | |
60 | + esac | |
61 | + done | |
62 | + | |
63 | + useradd -m -s /bin/bash ${_username} | |
64 | + groupadd sudo | |
65 | + usermod -G sudo ${_username} | |
66 | + cp -aT /etc/skel/ /home/${_username}/ | |
67 | + chmod 700 -R /home/${_username} | |
68 | + chown ${_username}:${_username} -R /home/${_username} | |
69 | + echo -e "${_password}\n${_password}" | passwd ${_username} | |
70 | + set -u | |
71 | +} | |
72 | + | |
73 | +create_user -u alter -p "${password}" | |
74 | + | |
53 | 75 | |
54 | 76 | |
55 | 77 | # Set to execute calamares without password as alter user. |
@@ -59,8 +81,25 @@ alter ALL=NOPASSWD: /usr/bin/calamares_polkit | ||
59 | 81 | EOF |
60 | 82 | |
61 | 83 | |
62 | -# Delete unnecessary files for Manjaro. | |
63 | -[[ -d /usr/share/calamares/branding/manjaro ]] && rm -rf /usr/share/calamares/branding/manjaro | |
84 | +# Delete unnecessary files. | |
85 | + | |
86 | +# Delete file only if file exists | |
87 | +# remove <file1> <file2> | |
88 | +function remove () { | |
89 | + local _list | |
90 | + local _file | |
91 | + _list=($(echo "$@")) | |
92 | + for _file in "${_list[@]}"; do | |
93 | + if [[ -f ${_file} ]]; then | |
94 | + rm -f "${_file}" | |
95 | + elif [[ -d ${_file} ]]; then | |
96 | + rm -rf "${_file}" | |
97 | + fi | |
98 | + done | |
99 | +} | |
100 | + | |
101 | +remove /usr/share/calamares/branding/manjaro | |
102 | +remove /usr/share/calamares/modules/mhwdcfg.conf | |
64 | 103 | |
65 | 104 | |
66 | 105 | # Replace wallpaper. |
@@ -88,11 +127,11 @@ fi | ||
88 | 127 | # Replace calamares settings when lts kernel is enabled. |
89 | 128 | if [[ -n ${kernel} ]]; then |
90 | 129 | # initcpio |
91 | - [[ -f /usr/share/calamares/modules/initcpio.conf ]] && rm -f /usr/share/calamares/modules/initcpio.conf | |
130 | + remove /usr/share/calamares/modules/initcpio.conf | |
92 | 131 | mv /usr/share/calamares/modules/initcpio/initcpio-${kernel}.conf /usr/share/calamares/modules/initcpio.conf |
93 | 132 | |
94 | 133 | # unpackfs |
95 | - [[ -f /usr/share/calamares/modules/unpackfs.conf ]] && rm -f /usr/share/calamares/modules/unpackfs.conf | |
134 | + remove /usr/share/calamares/modules/unpackfs.conf | |
96 | 135 | mv /usr/share/calamares/modules/unpackfs/unpackfs-${kernel}.conf /usr/share/calamares/modules/unpackfs.conf |
97 | 136 | fi |
98 | 137 | [[ -d /usr/share/calamares/modules/initcpio/ ]] && rm -rf /usr/share/calamares/modules/initcpio/ |
@@ -118,16 +157,27 @@ sed -i 's/#\(HandleLidSwitch=\)suspend/\1ignore/' /etc/systemd/logind.conf | ||
118 | 157 | |
119 | 158 | |
120 | 159 | # Create new icon cache |
160 | +# This is because alter icon was added by airootfs. | |
121 | 161 | gtk-update-icon-cache -f /usr/share/icons/hicolor |
122 | 162 | |
123 | 163 | |
164 | +# Enable services. | |
124 | 165 | # To disable start up of lightdm. |
125 | 166 | # If it is enable, Users have to enter password. |
126 | 167 | systemctl disable lightdm |
127 | 168 | if [[ ${boot_splash} = true ]]; then |
128 | 169 | systemctl disable lightdm-plymouth.service |
129 | 170 | fi |
130 | -systemctl enable pacman-init.service choose-mirror.service org.cups.cupsd.service | |
171 | +systemctl enable pacman-init.service | |
172 | +systemctl enable choose-mirror.service | |
173 | +systemctl enable org.cups.cupsd.service | |
174 | +systemctl enable NetworkManager.service | |
175 | + | |
176 | +# TLP | |
177 | +# See ArchWiki for details. | |
178 | +systemctl enable tlp.service | |
179 | +systemctl mask systemd-rfkill.service | |
180 | +systemctl mask systemd-rfkill.socket | |
131 | 181 | |
132 | 182 | |
133 | 183 | # systemctl set-default multi-user.target |
@@ -0,0 +1,8 @@ | ||
1 | +[Default Applications] | |
2 | +default-web-browser=chromium.desktop | |
3 | +text/html=chromium.desktop | |
4 | +x-scheme-handler/http=chromium.desktop | |
5 | +x-scheme-handler/https=chromium.desktop | |
6 | +x-scheme-handler/about=chromium.desktop | |
7 | +x-scheme-handler/unknown=chromium.desktop | |
8 | +application/pdf=chromium.desktop |
@@ -27,7 +27,7 @@ windowExpanding: normal | ||
27 | 27 | # This setting is ignored if "fullscreen" is selected for |
28 | 28 | # *windowExpanding*, above. If not set, use constants defined |
29 | 29 | # in CalamaresUtilsGui, 800x520. |
30 | -windowSize: 800px,520px | |
30 | +windowSize: 800px,580px | |
31 | 31 | |
32 | 32 | # These are strings shown to the user in the user interface. |
33 | 33 | # There is no provision for translating them -- since they |
@@ -1,21 +0,0 @@ | ||
1 | -#!/usr/bin/env bash | |
2 | - | |
3 | -function remove () { | |
4 | - local list | |
5 | - local file | |
6 | - local exit_code | |
7 | - list=($(echo "$@")) | |
8 | - for file in "${list[@]}"; do | |
9 | - if [[ -f ${file} ]]; then | |
10 | - rm -f "${file}" | |
11 | - elif [[ -d ${file} ]]; then | |
12 | - rm -rf "${file}" | |
13 | - fi | |
14 | - done | |
15 | -} | |
16 | - | |
17 | -remove /etc/skel/Desktop | |
18 | -remove /etc/systemd/system/getty@tty1.service.d/autologin.conf | |
19 | -remove /root/.automated_script.sh | |
20 | -remove /etc/mkinitcpio-archiso.conf | |
21 | -remove /etc/initcpio | |
\ No newline at end of file |
@@ -0,0 +1,62 @@ | ||
1 | +#!/usr/bin/env bash | |
2 | + | |
3 | +function remove () { | |
4 | + local list | |
5 | + local file | |
6 | + list=($(echo "$@")) | |
7 | + for file in "${list[@]}"; do | |
8 | + if [[ -f ${file} ]]; then | |
9 | + rm -f "${file}" | |
10 | + elif [[ -d ${file} ]]; then | |
11 | + rm -rf "${file}" | |
12 | + fi | |
13 | + done | |
14 | +} | |
15 | + | |
16 | +while getopts 'u:' arg; do | |
17 | + case "${arg}" in | |
18 | + u) user="${OPTARG}";; | |
19 | + esac | |
20 | +done | |
21 | + | |
22 | +remove /etc/skel/Desktop | |
23 | +remove /etc/skel/.config/gtk-3.0/bookmarks | |
24 | +remove /home/${user}/Desktop/calamares.desktop | |
25 | +remove /home/${user}/.config/gtk-3.0/bookmarks | |
26 | +remove /etc/systemd/system/getty@tty1.service.d/autologin.conf | |
27 | +remove /root/.automated_script.sh | |
28 | +remove /etc/mkinitcpio-archiso.conf | |
29 | +remove /etc/initcpio | |
30 | +remove /usr/share/calamares/ | |
31 | + | |
32 | +<<DISABLED | |
33 | +if [[ -f /home/${user}/.config/user-dirs.dirs ]]; then | |
34 | + HOME="/home/${user}" | |
35 | + source ${HOME}/.config/user-dirs.dirs | |
36 | + | |
37 | + # Add pictures to bookmark | |
38 | + echo -n "file://" >> ${HOME}/.config/gtk-3.0/bookmarks | |
39 | + echo -n "${XDG_PICTURES_DIR}" >> ${HOME}/.config/gtk-3.0/bookmarks | |
40 | + echo -ne "\n" >> ${HOME}/.config/gtk-3.0/bookmarks | |
41 | + | |
42 | + # Add videos to bookmark | |
43 | + echo -n "file://" >> ${HOME}/.config/gtk-3.0/bookmarks | |
44 | + echo -n "${XDG_VIDEOS_DIR}" >> ${HOME}/.config/gtk-3.0/bookmarks | |
45 | + echo -ne "\n" >> ${HOME}/.config/gtk-3.0/bookmarks | |
46 | + | |
47 | + # Add music to bookmark | |
48 | + echo -n "file://" >> ${HOME}/.config/gtk-3.0/bookmarks | |
49 | + echo -n "${XDG_VIDEOS_DIR}" >> ${HOME}/.config/gtk-3.0/bookmarks | |
50 | + echo -ne "\n" >> ${HOME}/.config/gtk-3.0/bookmarks | |
51 | + | |
52 | + # Add downloads to bookmark | |
53 | + echo -n "file://" >> ${HOME}/.config/gtk-3.0/bookmarks | |
54 | + echo -n "${XDG_DOWNLOAD_DIR}" >> ${HOME}/.config/gtk-3.0/bookmarks | |
55 | + echo -ne "\n" >> ${HOME}/.config/gtk-3.0/bookmarks | |
56 | + | |
57 | + # Add documents to bookmark | |
58 | + echo -n "file://" >> ${HOME}/.config/gtk-3.0/bookmarks | |
59 | + echo -n "${XDG_DOCUMENTS_DIR}" >> ${HOME}/.config/gtk-3.0/bookmarks | |
60 | + echo -ne "\n" >> ${HOME}/.config/gtk-3.0/bookmarks | |
61 | +fi | |
62 | +DISABLED | |
\ No newline at end of file |
@@ -0,0 +1,23 @@ | ||
1 | +# Run mkinitcpio(8) with the given preset value | |
2 | +--- | |
3 | +# This key defines the kernel to be loaded. | |
4 | +# It can have the following values: | |
5 | +# - empty or unset, interpreted as "all" | |
6 | +# - the literal string "$uname" (without quotes, with dollar), | |
7 | +# which will use the output of `uname -r` to determine the | |
8 | +# running kernel, and use that. | |
9 | +# - any other string. | |
10 | +# | |
11 | +# Whatever is set, that string is passed as *preset* argument to the | |
12 | +# `-p` option of *mkinitcpio*. Take care that both "$uname" operates | |
13 | +# in the host system, and might not be correct if the target system is | |
14 | +# updated (to a newer kernel) as part of the installation. | |
15 | +# | |
16 | +# Note that "all" is probably not a good preset to use either. | |
17 | +# kernel: linux312 | |
18 | +kernel: linux-lts | |
19 | + | |
20 | +# Set this to true to turn off mitigations for lax file | |
21 | +# permissions on initramfs (which, in turn, can compromise | |
22 | +# your LUKS encryption keys, CVS-2019-13179). | |
23 | +be_unsafe: false |
@@ -1,19 +0,0 @@ | ||
1 | ---- | |
2 | -bus: | |
3 | - - pci | |
4 | -# - usb | |
5 | - | |
6 | -identifier: | |
7 | - net: | |
8 | - - 200 | |
9 | - - 280 | |
10 | - video: | |
11 | - - 300 | |
12 | - - 302 | |
13 | - - 380 | |
14 | - | |
15 | -driver: free | |
16 | - | |
17 | -local: true | |
18 | - | |
19 | -repo: /opt/mhwd/pacman-mhwd.conf |
@@ -36,8 +36,8 @@ backend: pacman | ||
36 | 36 | # Therefore set also "update_system" to 'true'. |
37 | 37 | # |
38 | 38 | skip_if_no_internet: true |
39 | -update_db: false | |
40 | -update_system: false | |
39 | +update_db: true | |
40 | +update_system: true | |
41 | 41 | |
42 | 42 | # |
43 | 43 | # List of maps with package operations such as install or remove. |
@@ -161,11 +161,16 @@ update_system: false | ||
161 | 161 | # "binutils", and then a second time for "wget". When installing large numbers |
162 | 162 | # of packages, this can lead to a considerable time savings. |
163 | 163 | # |
164 | -#operations: | |
164 | +operations: | |
165 | 165 | # - install: |
166 | -# - vi | |
167 | -# - vi-${LOCALE} | |
168 | -# - wget | |
169 | -# - binutils | |
170 | -# - remove: | |
171 | -# - alterlinux-calamares | |
166 | + - remove: | |
167 | + - calamares | |
168 | + - boost-libs | |
169 | + - ckbcomp | |
170 | + - kpmcore3 | |
171 | + - mkinitcpio-openswap | |
172 | + - plasma-framework | |
173 | + - qt5-xmlpatterns | |
174 | + - squashfs-tools | |
175 | + - yaml-cpp | |
176 | + - arch-install-scripts |
@@ -67,7 +67,6 @@ | ||
67 | 67 | #targets: [] |
68 | 68 | #disable: [] |
69 | 69 | disable-targets: [] |
70 | -mask: [] | |
71 | 70 | |
72 | 71 | # Manjaro settings |
73 | 72 |
@@ -79,18 +78,28 @@ services: | ||
79 | 78 | mandatory: false |
80 | 79 | |
81 | 80 | - name: "lightdm-plymouth" |
82 | - mandatory: true | |
81 | + mandatory: false | |
83 | 82 | |
84 | 83 | - name: "pacman-init" |
85 | 84 | mandatory: false |
85 | + | |
86 | + - name: "tlp" | |
87 | + mandatory: false | |
88 | + | |
89 | + - name: "tlp-sleep" | |
90 | + mandatory: false | |
86 | 91 | |
87 | 92 | targets: |
88 | 93 | - name: "graphical" |
89 | 94 | mandatory: true |
90 | 95 | |
91 | 96 | disable: |
92 | - - name: "lightdm" | |
93 | - mandatory: true | |
94 | - | |
95 | 97 | - name: "dhcpcd" |
96 | 98 | mandatory: false |
99 | + | |
100 | +mask: | |
101 | + - name: "systemd-rfkill" | |
102 | + mandatory: false | |
103 | + | |
104 | + - name: "systemd-rfkill.socket" | |
105 | + mandatory: false | |
\ No newline at end of file |
@@ -67,7 +67,6 @@ | ||
67 | 67 | #targets: [] |
68 | 68 | #disable: [] |
69 | 69 | disable-targets: [] |
70 | -mask: [] | |
71 | 70 | |
72 | 71 | # Manjaro settings |
73 | 72 |
@@ -83,6 +82,12 @@ services: | ||
83 | 82 | |
84 | 83 | - name: "pacman-init" |
85 | 84 | mandatory: false |
85 | + | |
86 | + - name: "tlp" | |
87 | + mandatory: false | |
88 | + | |
89 | + - name: "tlp-sleep" | |
90 | + mandatory: false | |
86 | 91 | |
87 | 92 | targets: |
88 | 93 | - name: "graphical" |
@@ -90,4 +95,11 @@ targets: | ||
90 | 95 | |
91 | 96 | disable: |
92 | 97 | - name: "dhcpcd" |
98 | + mandatory: false | |
99 | + | |
100 | +mask: | |
101 | + - name: "systemd-rfkill" | |
102 | + mandatory: false | |
103 | + | |
104 | + - name: "systemd-rfkill.socket" | |
93 | 105 | mandatory: false |
\ No newline at end of file |
@@ -30,6 +30,5 @@ | ||
30 | 30 | dontChroot: false |
31 | 31 | timeout: 50 |
32 | 32 | script: |
33 | - - "chmod 755 /usr/share/calamares/cleaning.sh" | |
34 | - - "/usr/share/calamares/cleaning.sh" | |
35 | - - "rm /home/@@USER@@/Desktop/calamares.desktop" | |
33 | + - "chmod 755 /usr/share/calamares/final-process" | |
34 | + - "/usr/share/calamares/final-process -u @@USER@@" |
@@ -0,0 +1,97 @@ | ||
1 | +# Unsquash / unpack a filesystem. Multiple sources are supported, and | |
2 | +# they may be squashed or plain filesystems. | |
3 | +# | |
4 | +# Configuration: | |
5 | +# | |
6 | +# from globalstorage: rootMountPoint | |
7 | +# from job.configuration: the path to where to mount the source image(s) | |
8 | +# for copying an ordered list of unpack mappings for image file <-> | |
9 | +# target dir relative to rootMountPoint. | |
10 | + | |
11 | +--- | |
12 | +# Each list item is unpacked, in order, to the target system. | |
13 | +# | |
14 | +# Each list item has the following **mandatory** attributes: | |
15 | +# - *source* path relative to the live / intstalling system to the image | |
16 | +# - *sourcefs* the type of the source files; valid entries are | |
17 | +# - `ext4` (copies the filesystem contents) | |
18 | +# - `squashfs` (unsquashes) | |
19 | +# - `file` (copies a file or directory) | |
20 | +# - (may be others if mount supports it) | |
21 | +# - *destination* path relative to rootMountPoint (so in the target | |
22 | +# system) where this filesystem is unpacked. It may be an | |
23 | +# empty string, which effectively is / (the root) of the target | |
24 | +# system. | |
25 | +# | |
26 | +# Each list item **optionally** can include the following attributes: | |
27 | +# - *exclude* is a list of values that is expanded into --exclude | |
28 | +# arguments for rsync (each entry in exclude gets its own --exclude). | |
29 | +# - *excludeFile* is a single file that is passed to rsync as an | |
30 | +# --exclude-file argument. This should be a full pathname | |
31 | +# inside the **host** filesystem. | |
32 | +# | |
33 | +# EXAMPLES | |
34 | +# | |
35 | +# Usually you list a filesystem image to unpack; you can use | |
36 | +# squashfs or an ext4 image. An empty destination is equivalent to "/", | |
37 | +# the root of the target system. The destination directory must exist | |
38 | +# in the target system. | |
39 | +# | |
40 | +# - source: "/path/to/filesystem.sqfs" | |
41 | +# sourcefs: "squashfs" | |
42 | +# destination: "" | |
43 | +# | |
44 | +# Multiple entries are unpacked in-order; if there is more than one | |
45 | +# item then only the first must exist beforehand -- it's ok to | |
46 | +# create directories with one unsquash and then to use those | |
47 | +# directories as a target from a second unsquash. | |
48 | +# | |
49 | +# - source: "/path/to/another/filesystem.img" | |
50 | +# sourcefs: "ext4" | |
51 | +# destination: "" | |
52 | +# - source: "/path/to/another/filesystem2.img" | |
53 | +# sourcefs: "ext4" | |
54 | +# destination: "/usr/lib/extra" | |
55 | +# | |
56 | +# You can list filesystem source paths relative to the Calamares run | |
57 | +# directory, if you use -d (this is only useful for testing, though). | |
58 | +# | |
59 | +# - source: ./example.sqfs | |
60 | +# sourcefs: squashfs | |
61 | +# destination: "" | |
62 | +# | |
63 | +# You can list individual files (copied one-by-one), or directories | |
64 | +# (the files inside this directory are copied directly to the destination, | |
65 | +# so no "dummycpp/" subdirectory is created in this example). | |
66 | +# Do note that the target directory must exist already (e.g. from | |
67 | +# extracting some other filesystem). | |
68 | +# | |
69 | +# - source: ../CHANGES | |
70 | +# sourcefs: file | |
71 | +# destination: "/tmp/derp" | |
72 | +# - source: ../src/modules/dummycpp | |
73 | +# sourcefs: file | |
74 | +# destination: "/tmp/derp" | |
75 | +# | |
76 | +# The *destination* and *source* are handed off to rsync, so the semantics | |
77 | +# of trailing slashes apply. In order to *rename* a file as it is | |
78 | +# copied, specify one single file (e.g. CHANGES) and a full pathname | |
79 | +# for its destination name, as in the example below. | |
80 | + | |
81 | +#unpack: | |
82 | +# - source: ../CHANGES | |
83 | +# sourcefs: file | |
84 | +# destination: "/tmp/changes.txt" | |
85 | +# - source: src/qml/calamares/slideshow | |
86 | +# sourcefs: file | |
87 | +# destination: "/tmp/slideshow/" | |
88 | +# exclude: [ "*.qmlc", "qmldir" ] | |
89 | +# # excludeFile: /etc/calamares/modules/unpackfs/exclude-list.txt | |
90 | + | |
91 | +unpack: | |
92 | + - source: "/run/archiso/bootmnt/alter/x86_64/airootfs.sfs" | |
93 | + sourcefs: "squashfs" | |
94 | + destination: "" | |
95 | + - source: "/run/archiso/bootmnt/alter/boot/x86_64/vmlinuz-linux-lts" | |
96 | + sourcefs: "file" | |
97 | + destination: "/boot/vmlinuz-linux-lts" |
@@ -109,10 +109,9 @@ sequence: | ||
109 | 109 | - removeuser |
110 | 110 | - users |
111 | 111 | - displaymanager |
112 | - - mhwdcfg | |
113 | 112 | - networkcfg |
114 | 113 | - hwclock |
115 | - # - packages | |
114 | + - packages | |
116 | 115 | - services |
117 | 116 | - grubcfg |
118 | 117 | - bootloader |
@@ -16,7 +16,7 @@ install_dir=alter | ||
16 | 16 | work_dir=work |
17 | 17 | out_dir=out |
18 | 18 | gpg_key= |
19 | -verbose="-v" | |
19 | +alteriso_option="-v" | |
20 | 20 | |
21 | 21 | # AlterLinux settings |
22 | 22 | password=alter |
@@ -26,8 +26,9 @@ theme_name="alter-logo" | ||
26 | 26 | theme_pkg="plymouth-theme-alter-logo-git" |
27 | 27 | sfs_comp="zstd" |
28 | 28 | sfs_comp_opt="" |
29 | +debug=false | |
29 | 30 | |
30 | -# Load extra settings | |
31 | +# Load config file | |
31 | 32 | [[ -f ./config ]] && source config; echo "The settings have been overwritten by the config file." |
32 | 33 | |
33 | 34 | script_path=$(readlink -f ${0%/*}) |
@@ -67,9 +68,28 @@ _usage () { | ||
67 | 68 | echo " -w <work_dir> Set the working directory" |
68 | 69 | echo " Default: ${work_dir}" |
69 | 70 | echo " -h This help message" |
71 | + echo " -x Enable debug mode." | |
70 | 72 | exit ${1} |
71 | 73 | } |
72 | 74 | |
75 | +# Check the value of a variable that can only be set to true or false. | |
76 | +case ${boot_splash} in | |
77 | + true) : ;; | |
78 | + false) : ;; | |
79 | + *) | |
80 | + echo "The value ${boot_splash} set is invalid" >&2 | |
81 | + ;; | |
82 | +esac | |
83 | + | |
84 | +case ${debug} in | |
85 | + true) : ;; | |
86 | + false) : ;; | |
87 | + *) | |
88 | + echo "The value ${debug} set is invalid" >&2 | |
89 | + ;; | |
90 | +esac | |
91 | + | |
92 | + | |
73 | 93 | # Helper function to run make_*() only one time per architecture. |
74 | 94 | run_once() { |
75 | 95 | if [[ ! -e ${work_dir}/build.${1} ]]; then |
@@ -87,30 +107,30 @@ make_pacman_conf() { | ||
87 | 107 | |
88 | 108 | # Base installation, plus needed packages (airootfs) |
89 | 109 | make_basefs() { |
90 | - mkarchiso ${verbose} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" init | |
91 | - # mkarchiso ${verbose} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" -p "haveged intel-ucode amd-ucode memtest86+ mkinitcpio-nfs-utils nbd zsh efitools" install | |
92 | - mkarchiso ${verbose} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" -p "haveged intel-ucode amd-ucode mkinitcpio-nfs-utils nbd efitools" install | |
110 | + mkarchiso ${alteriso_option} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" init | |
111 | + # mkarchiso ${alteriso_option} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" -p "haveged intel-ucode amd-ucode memtest86+ mkinitcpio-nfs-utils nbd zsh efitools" install | |
112 | + mkarchiso ${alteriso_option} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" -p "haveged intel-ucode amd-ucode mkinitcpio-nfs-utils nbd efitools" install | |
93 | 113 | |
94 | 114 | # Install plymouth. |
95 | 115 | if [[ ${boot_splash} = true ]]; then |
96 | 116 | if [[ -n ${theme_pkg} ]]; then |
97 | - mkarchiso ${verbose} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" -p "plymouth ${theme_pkg}" install | |
117 | + mkarchiso ${alteriso_option} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" -p "plymouth ${theme_pkg}" install | |
98 | 118 | else |
99 | - mkarchiso ${verbose} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" -p "plymouth" install | |
119 | + mkarchiso ${alteriso_option} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" -p "plymouth" install | |
100 | 120 | fi |
101 | 121 | fi |
102 | 122 | |
103 | 123 | # Install kernel. |
104 | 124 | if [[ -n ${kernel} ]]; then |
105 | - mkarchiso ${verbose} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" -p "linux-${kernel} linux-${kernel}-headers broadcom-wl-dkms" install | |
125 | + mkarchiso ${alteriso_option} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" -p "linux-${kernel} linux-${kernel}-headers broadcom-wl-dkms" install | |
106 | 126 | else |
107 | - mkarchiso ${verbose} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" -p "linux linux-headers broadcom-wl" install | |
127 | + mkarchiso ${alteriso_option} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" -p "linux linux-headers broadcom-wl" install | |
108 | 128 | fi |
109 | 129 | } |
110 | 130 | |
111 | 131 | # Additional packages (airootfs) |
112 | 132 | make_packages() { |
113 | - mkarchiso ${verbose} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" -p "$(grep -h -v ^'#' ${script_path}/packages.x86_64)" install | |
133 | + mkarchiso ${alteriso_option} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" -p "$(grep -h -v ^'#' ${script_path}/packages.x86_64)" install | |
114 | 134 | } |
115 | 135 | |
116 | 136 | # Copy mkinitcpio archiso hooks and build initramfs (airootfs) |
@@ -137,9 +157,9 @@ make_setup_mkinitcpio() { | ||
137 | 157 | fi |
138 | 158 | |
139 | 159 | if [[ -n ${kernel} ]]; then |
140 | - ARCHISO_GNUPG_FD=${gpg_key:+17} mkarchiso ${verbose} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" -r "mkinitcpio -c /etc/mkinitcpio-archiso.conf -k /boot/vmlinuz-linux-${kernel} -g /boot/archiso.img" run | |
160 | + ARCHISO_GNUPG_FD=${gpg_key:+17} mkarchiso ${alteriso_option} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" -r "mkinitcpio -c /etc/mkinitcpio-archiso.conf -k /boot/vmlinuz-linux-${kernel} -g /boot/archiso.img" run | |
141 | 161 | else |
142 | - ARCHISO_GNUPG_FD=${gpg_key:+17} mkarchiso ${verbose} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" -r 'mkinitcpio -c /etc/mkinitcpio-archiso.conf -k /boot/vmlinuz-linux -g /boot/archiso.img' run | |
162 | + ARCHISO_GNUPG_FD=${gpg_key:+17} mkarchiso ${alteriso_option} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" -r 'mkinitcpio -c /etc/mkinitcpio-archiso.conf -k /boot/vmlinuz-linux -g /boot/archiso.img' run | |
143 | 163 | fi |
144 | 164 | |
145 | 165 | if [[ ${gpg_key} ]]; then |
@@ -167,24 +187,28 @@ make_customize_airootfs() { | ||
167 | 187 | # -b : Enable boot splash. |
168 | 188 | # -t : Set plymouth theme. |
169 | 189 | # -k <kernel> : Set kernel name. |
190 | + # -x : Enable debug mode. | |
170 | 191 | |
171 | 192 | |
172 | 193 | local options |
173 | 194 | options= |
174 | 195 | if [[ ${boot_splash} = true ]]; then |
175 | 196 | if [[ -z ${theme_name} ]]; then |
176 | - options="-b" | |
197 | + options="${options} -b" | |
177 | 198 | else |
178 | - options="-b -t ${theme_name}" | |
199 | + options="${options} -b -t ${theme_name}" | |
179 | 200 | fi |
180 | 201 | fi |
181 | 202 | if [[ -n ${kernel} ]]; then |
182 | 203 | options="${options} -k ${kernel}" |
183 | 204 | fi |
205 | + if ${debug}; then | |
206 | + options="${options} -x" | |
207 | + fi | |
184 | 208 | if [[ -z ${options} ]]; then |
185 | - mkarchiso ${verbose} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" -r "/root/customize_airootfs.sh -p ${password}" run | |
209 | + mkarchiso ${alteriso_option} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" -r "/root/customize_airootfs.sh -p ${password}" run | |
186 | 210 | else |
187 | - mkarchiso ${verbose} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" -r "/root/customize_airootfs.sh -p ${password} ${options}" run | |
211 | + mkarchiso ${alteriso_option} -w "${work_dir}/x86_64" -C "${work_dir}/pacman.conf" -D "${install_dir}" -r "/root/customize_airootfs.sh -p ${password} ${options}" run | |
188 | 212 | fi |
189 | 213 | rm ${work_dir}/x86_64/airootfs/root/customize_airootfs.sh |
190 | 214 | } |
@@ -345,15 +369,15 @@ make_efiboot() { | ||
345 | 369 | # Build airootfs filesystem image |
346 | 370 | make_prepare() { |
347 | 371 | cp -a -l -f ${work_dir}/x86_64/airootfs ${work_dir} |
348 | - mkarchiso ${verbose} -w "${work_dir}" -D "${install_dir}" pkglist | |
349 | - mkarchiso ${verbose} -w "${work_dir}" -D "${install_dir}" ${gpg_key:+-g ${gpg_key}} -c "${sfs_comp}" -t "${sfs_comp_opt}" prepare | |
372 | + mkarchiso ${alteriso_option} -w "${work_dir}" -D "${install_dir}" pkglist | |
373 | + mkarchiso ${alteriso_option} -w "${work_dir}" -D "${install_dir}" ${gpg_key:+-g ${gpg_key}} -c "${sfs_comp}" -t "${sfs_comp_opt}" prepare | |
350 | 374 | rm -rf ${work_dir}/airootfs |
351 | 375 | # rm -rf ${work_dir}/x86_64/airootfs (if low space, this helps) |
352 | 376 | } |
353 | 377 | |
354 | 378 | # Build ISO |
355 | 379 | make_iso() { |
356 | - mkarchiso ${verbose} -w "${work_dir}" -D "${install_dir}" -L "${iso_label}" -P "${iso_publisher}" -A "${iso_application}" -o "${out_dir}" iso "${iso_name}-${iso_version}-x86_64.iso" | |
380 | + mkarchiso ${alteriso_option} -w "${work_dir}" -D "${install_dir}" -L "${iso_label}" -P "${iso_publisher}" -A "${iso_application}" -o "${out_dir}" iso "${iso_name}-${iso_version}-x86_64.iso" | |
357 | 381 | } |
358 | 382 | |
359 | 383 | if [[ ${EUID} -ne 0 ]]; then |
@@ -361,7 +385,7 @@ if [[ ${EUID} -ne 0 ]]; then | ||
361 | 385 | _usage 1 |
362 | 386 | fi |
363 | 387 | |
364 | -while getopts 'w:o:g:p:c:t:hbk:' arg; do | |
388 | +while getopts 'w:o:g:p:c:t:hbk:x' arg; do | |
365 | 389 | case "${arg}" in |
366 | 390 | p) password="${OPTARG}" ;; |
367 | 391 | w) work_dir="${OPTARG}" ;; |
@@ -379,26 +403,30 @@ while getopts 'w:o:g:p:c:t:hbk:' arg; do | ||
379 | 403 | t) sfs_comp_opt=${OPTARG} ;; |
380 | 404 | b) boot_splash=true ;; |
381 | 405 | k) |
382 | - case ${OPTARG} in | |
383 | - "lts") kernel=lts ;; | |
384 | - "lqx") kernel=lqx ;; | |
385 | - "zen") kernel=zen ;; | |
386 | - "ck") kernel=ck ;; | |
387 | - "rt") kernel=rt ;; | |
388 | - *) | |
389 | - echo "Invalid kernel ${OPTARG}" | |
390 | - _usage 1 | |
391 | - ;; | |
392 | - esac | |
406 | + if [[ -n $(cat ./kernel_list | grep -x "${OPTARG}") ]]; then | |
407 | + kernel="${OPTARG}" | |
408 | + else | |
409 | + echo "Invalid kernel ${OPTARG}" >&2 | |
410 | + _usage 1 | |
411 | + fi | |
393 | 412 | ;; |
413 | + x) debug=true;; | |
394 | 414 | h) _usage 0 ;; |
395 | 415 | *) |
396 | - echo "Invalid argument '${arg}'" | |
416 | + echo "Invalid argument '${arg}'" >&2 | |
397 | 417 | _usage 1 |
398 | 418 | ;; |
399 | 419 | esac |
400 | 420 | done |
401 | 421 | |
422 | +# Debug mode | |
423 | +if ${debug}; then | |
424 | + set -x | |
425 | + alteriso_option="${alteriso_option} -x" | |
426 | +else | |
427 | + set +x | |
428 | +fi | |
429 | + | |
402 | 430 | mkdir -p ${work_dir} |
403 | 431 | |
404 | 432 | # Show Alter Linux build options. |
@@ -408,7 +436,6 @@ echo "Live user password is ${password}." | ||
408 | 436 | echo "The compression method of squashfs is ${sfs_comp}." |
409 | 437 | sleep 2 |
410 | 438 | |
411 | - | |
412 | 439 | run_once make_pacman_conf |
413 | 440 | run_once make_basefs |
414 | 441 | run_once make_packages |
@@ -55,4 +55,9 @@ sfs_comp_opt="" | ||
55 | 55 | # Set the kernel that live session use. |
56 | 56 | # Please don't set anything if you want to use normal kernel. |
57 | 57 | # As of February 23, 2020, the available kernels are lts, zen, ck, , rt and lqx. |
58 | -kernel= | |
\ No newline at end of file | ||
58 | +kernel= | |
59 | + | |
60 | +# Set debug mode. | |
61 | +# This setting can only be set to true or false. | |
62 | +# When enabled, bash debug mode is enabled, making it easier to identify which command caused the error. | |
63 | +debug=false | |
\ No newline at end of file |
@@ -0,0 +1,6 @@ | ||
1 | +title Alter Linux archiso x86_64 UEFI CD | |
2 | +linux /EFI/archiso/vmlinuz-linux-lts.efi | |
3 | +initrd /EFI/archiso/intel_ucode.img | |
4 | +initrd /EFI/archiso/amd_ucode.img | |
5 | +initrd /EFI/archiso/archiso.img | |
6 | +options archisobasedir=%INSTALL_DIR% archisolabel=%ARCHISO_LABEL% |
@@ -0,0 +1,6 @@ | ||
1 | +title Alter Linux archiso x86_64 UEFI USB | |
2 | +linux /%INSTALL_DIR%/boot/x86_64/vmlinuz-linux-lts | |
3 | +initrd /%INSTALL_DIR%/boot/intel_ucode.img | |
4 | +initrd /%INSTALL_DIR%/boot/amd_ucode.img | |
5 | +initrd /%INSTALL_DIR%/boot/x86_64/archiso.img | |
6 | +options archisobasedir=%INSTALL_DIR% archisolabel=%ARCHISO_LABEL% |
@@ -0,0 +1,6 @@ | ||
1 | +lts | |
2 | +lqx | |
3 | +zen | |
4 | +ck | |
5 | +rt | |
6 | +rt-lts | |
\ No newline at end of file |
@@ -44,7 +44,7 @@ _msg_error() { | ||
44 | 44 | |
45 | 45 | _chroot_init() { |
46 | 46 | mkdir -p ${work_dir}/airootfs |
47 | - _pacman "base syslinux" | |
47 | + _pacman "base base-devel syslinux" | |
48 | 48 | } |
49 | 49 | |
50 | 50 | _chroot_run() { |
@@ -380,7 +380,7 @@ fi | ||
380 | 380 | |
381 | 381 | umask 0022 |
382 | 382 | |
383 | -while getopts 'p:r:C:L:P:A:D:w:o:s:c:g:t:vh' arg; do | |
383 | +while getopts 'p:r:C:L:P:A:D:w:o:s:c:g:t:vhx' arg; do | |
384 | 384 | case "${arg}" in |
385 | 385 | p) pkg_list="${pkg_list} ${OPTARG}" ;; |
386 | 386 | r) run_cmd="${OPTARG}" ;; |
@@ -396,6 +396,7 @@ while getopts 'p:r:C:L:P:A:D:w:o:s:c:g:t:vh' arg; do | ||
396 | 396 | t) sfs_comp_opt="${OPTARG}" ;; |
397 | 397 | g) gpg_key="${OPTARG}" ;; |
398 | 398 | v) quiet="n" ;; |
399 | + x) set -x ;; | |
399 | 400 | h|?) _usage 0 ;; |
400 | 401 | *) |
401 | 402 | _msg_error "Invalid argument '${arg}'" 0 |
@@ -53,9 +53,11 @@ irssi | ||
53 | 53 | |
54 | 54 | #-- display manager --# |
55 | 55 | lightdm |
56 | -#lightdm-gtk-greeter | |
57 | -lightdm-slick-greeter | |
58 | -lightdm-settings | |
56 | +lightdm-webkit2-greeter | |
57 | +lightdm-webkit2-theme-alter | |
58 | +# lightdm-gtk-greeter | |
59 | +# lightdm-slick-greeter | |
60 | +# lightdm-settings | |
59 | 61 | |
60 | 62 | |
61 | 63 | #-- disk management --# |
@@ -126,6 +128,7 @@ dnsutils | ||
126 | 128 | ndisc6 |
127 | 129 | netctl |
128 | 130 | networkmanager |
131 | +network-manager-applet | |
129 | 132 | ppp |
130 | 133 | pptpclient |
131 | 134 | rp-pppoe |
@@ -191,7 +194,7 @@ viewnior | ||
191 | 194 | vlc |
192 | 195 | |
193 | 196 | |
194 | -#-- pacmage management --# | |
197 | +#-- package management --# | |
195 | 198 | eg-installer |
196 | 199 | pamac-gtk |
197 | 200 | yay-bin |
@@ -217,6 +220,12 @@ nano | ||
217 | 220 | xdg-user-dirs |
218 | 221 | |
219 | 222 | |
223 | +#-- utility --# | |
224 | +etcher-bin | |
225 | +tlp | |
226 | +tlpui | |
227 | + | |
228 | + | |
220 | 229 | #-- web browser --# |
221 | 230 | chromium |
222 | 231 | # elinks |
@@ -225,10 +234,12 @@ chromium | ||
225 | 234 | #-- xfce4 base --# |
226 | 235 | exo |
227 | 236 | garcon |
237 | +gnome-keyring | |
228 | 238 | thunar |
229 | 239 | thunar-volman |
230 | 240 | tumbler |
231 | 241 | xfce4-appfinder |
242 | +xfce4-notifyd | |
232 | 243 | xfce4-screenshooter |
233 | 244 | xfce4-session |
234 | 245 | xfce4-settings |
@@ -0,0 +1,58 @@ | ||
1 | +## 日本語 | |
2 | + | |
3 | +### 新しいカーネルに対応させる | |
4 | + | |
5 | +Alter Linuxを新しいカーネルに対応させる手順です。ここでは`linux-fooo`を追加する手順を説明します。実際に行う場合はこの文字を置き換えてください。 | |
6 | +リポジトリには2種類のパッケージを追加する必要があります。カーネル本体とheadersパッケージです。 | |
7 | + | |
8 | + | |
9 | +#### 1.リポジトリを作成する | |
10 | + | |
11 | +`build.sh`はカーネルをpacmanを利用してインストールしようとします。もしあなたが公式リポジトリに無いカーネルを追加したい場合はまずはpacmanのリポジトリを作成してください。 | |
12 | +リポジトリはGitHubを利用して簡単に作成できます。 | |
13 | + | |
14 | +#### 2.カーネル一覧に追加する | |
15 | + | |
16 | +`kernel_list`にカーネル名を追記してください。`build.sh`に渡された値が正しいかどうかはこの変数を利用して判定されます。 | |
17 | +リストに追加する値は`linux-`の後の文字です。今回の場合は`fooo`になります。 | |
18 | + | |
19 | +```bash | |
20 | +echo "fooo" >> ./kernel_list | |
21 | +``` | |
22 | + | |
23 | +#### 3.ファイルを作成する | |
24 | +そのカーネル用のファイルを6つ作成する必要があります。以下はカーネルの一覧です。 | |
25 | +「既存のファイルを名前を変えてコピーし、カーネルへのパスを修正する」という作成砲お方が最も簡単です。 | |
26 | +ファイル名は`fooo`に置き換えてあります。 | |
27 | +- syslinux/archiso_sys/archiso_sys-fooo.cfg | |
28 | +- syslinux/archiso_pxe/archiso_pxe-fooo.cfg | |
29 | +- efiboot/loader/entries/cd/archiso-x86_64-cd-fooo.conf | |
30 | +- efiboot/loader/entries/usb/archiso-x86_64-usb-fooo.conf | |
31 | +- airootfs/usr/share/calamares/modules/unpackfs/unpackfs-fooo.conf | |
32 | +- airootfs/usr/share/calamares/modules/initcpio/initcpio-fooo.conf | |
33 | + | |
34 | +##### archiso_sys-fooo.cfg | |
35 | + | |
36 | +9行目のパスを変更してください。 | |
37 | + | |
38 | +##### archiso_pxe-fooo.cfg | |
39 | + | |
40 | +9行目、20行目、31行目のパスを変更してください。 | |
41 | + | |
42 | +##### archiso-x86_64-cd-fooo.conf | |
43 | + | |
44 | +2行目のパスを変更してください。 | |
45 | + | |
46 | +##### archiso-x86_64-usb-fooo.conf | |
47 | + | |
48 | +2行目のパスを変更してください。 | |
49 | + | |
50 | +##### unpackfs-fooo.conf | |
51 | +95行目、97行目のパスを変更してください。 | |
52 | + | |
53 | +##### initcpio-fooo.conf | |
54 | +18行目のパスを変更してください。 | |
55 | + | |
56 | +#### 4.プルリクエストを送る | |
57 | +[ここ](https://github.com/SereneTeam/alterlinux/pulls)へプルリクエストを投稿してください。 | |
58 | + |
@@ -0,0 +1,36 @@ | ||
1 | +INCLUDE boot/syslinux/archiso_head.cfg | |
2 | + | |
3 | +LABEL arch64_nbd | |
4 | +TEXT HELP | |
5 | +Boot the Alter Linux (x86_64) live medium (Using NBD). | |
6 | +It allows you to install Alter Linux or perform system maintenance. | |
7 | +ENDTEXT | |
8 | +MENU LABEL Boot Alter Linux (x86_64) (NBD) | |
9 | +LINUX boot/x86_64/vmlinuz-linux-lts | |
10 | +INITRD boot/intel_ucode.img,boot/amd_ucode.img,boot/x86_64/archiso.img | |
11 | +APPEND archisobasedir=%INSTALL_DIR% archisolabel=%ARCHISO_LABEL% archiso_nbd_srv=${pxeserver} | |
12 | +SYSAPPEND 3 | |
13 | + | |
14 | +LABEL arch64_nfs | |
15 | +TEXT HELP | |
16 | +Boot the Alter Linux (x86_64) live medium (Using NFS). | |
17 | +It allows you to install Alter Linux or perform system maintenance. | |
18 | +ENDTEXT | |
19 | +MENU LABEL Boot Alter Linux (x86_64) (NFS) | |
20 | +LINUX boot/x86_64/vmlinuz-linux-lts | |
21 | +INITRD boot/intel_ucode.img,boot/amd_ucode.img,boot/x86_64/archiso.img | |
22 | +APPEND archisobasedir=%INSTALL_DIR% archiso_nfs_srv=${pxeserver}:/run/archiso/bootmnt | |
23 | +SYSAPPEND 3 | |
24 | + | |
25 | +LABEL arch64_http | |
26 | +TEXT HELP | |
27 | +Boot the Alter Linux (x86_64) live medium (Using HTTP). | |
28 | +It allows you to install Alter Linux or perform system maintenance. | |
29 | +ENDTEXT | |
30 | +MENU LABEL Boot Alter Linux (x86_64) (HTTP) | |
31 | +LINUX boot/x86_64/vmlinuz-linux-lts | |
32 | +INITRD boot/intel_ucode.img,boot/amd_ucode.img,boot/x86_64/archiso.img | |
33 | +APPEND archisobasedir=%INSTALL_DIR% archiso_http_srv=http://${pxeserver}/ | |
34 | +SYSAPPEND 3 | |
35 | + | |
36 | +INCLUDE boot/syslinux/archiso_tail.cfg |
@@ -0,0 +1,13 @@ | ||
1 | +INCLUDE boot/syslinux/archiso_head.cfg | |
2 | + | |
3 | +LABEL arch64 | |
4 | +TEXT HELP | |
5 | +Boot the Alter Linux (x86_64) live medium. | |
6 | +It allows you to install Alter Linux or perform system maintenance. | |
7 | +ENDTEXT | |
8 | +MENU LABEL Boot Alter Linux (x86_64) | |
9 | +LINUX boot/x86_64/vmlinuz-linux-rt-lts | |
10 | +INITRD boot/intel_ucode.img,boot/amd_ucode.img,boot/x86_64/archiso.img | |
11 | +APPEND archisobasedir=%INSTALL_DIR% archisolabel=%ARCHISO_LABEL% | |
12 | + | |
13 | +INCLUDE boot/syslinux/archiso_tail.cfg |
@@ -153,9 +153,63 @@ function set_password () { | ||
153 | 153 | set_password |
154 | 154 | fi |
155 | 155 | unset confirm |
156 | - echo | |
157 | 156 | } |
158 | 157 | |
158 | +function select_kernel () { | |
159 | + set +e | |
160 | + local do_you_want_to_select_kernel | |
161 | + | |
162 | + function do_you_want_to_select_kernel () { | |
163 | + set +e | |
164 | + local yn | |
165 | + echo -n "通常以外のLinuxカーネルを使用しますか? (y/N) : " | |
166 | + read yn | |
167 | + case ${yn} in | |
168 | + y | Y | yes | Yes | YES ) return 0 ;; | |
169 | + n | N | no | No | NO ) return 1 ;; | |
170 | + * ) do_you_want_to_select_kernel ; return;; | |
171 | + esac | |
172 | + | |
173 | + } | |
174 | + | |
175 | + local what_kernel | |
176 | + | |
177 | + function what_kernel () { | |
178 | + echo "使用するカーネルを以下の番号から選択してください " | |
179 | + echo | |
180 | + echo "1: linux-lts" | |
181 | + echo "2: linux-zen" | |
182 | + echo "3: linux-ck" | |
183 | + echo "4: linux-rt" | |
184 | + echo "5: linux-lqx" | |
185 | + echo -n ": " | |
186 | + | |
187 | + read yn | |
188 | + | |
189 | + case ${yn} in | |
190 | + 1) kernel="lts" ;; | |
191 | + 2) kernel="zen" ;; | |
192 | + 3) kernel="ck" ;; | |
193 | + 4) kernel="rt" ;; | |
194 | + 5) kernel="lqx" ;; | |
195 | + lts) kernel="lts" ;; | |
196 | + zen) kernel="zen" ;; | |
197 | + ck) kernel="ck" ;; | |
198 | + rt) kernel="rt" ;; | |
199 | + lqx) kernel="lqx" ;; | |
200 | + *) what_kernel ;; | |
201 | + esac | |
202 | + } | |
203 | + | |
204 | + do_you_want_to_select_kernel | |
205 | + exit_code=$? | |
206 | + if [[ ${exit_code} = 0 ]]; then | |
207 | + what_kernel | |
208 | + fi | |
209 | + set -e | |
210 | +} | |
211 | + | |
212 | + | |
159 | 213 | # 最終的なbuild.shのオプションを生成 |
160 | 214 | function generate_argument () { |
161 | 215 | if [[ ${plymouth} = true ]]; then |
@@ -164,6 +218,9 @@ function generate_argument () { | ||
164 | 218 | if [[ -n ${comp_type} ]]; then |
165 | 219 | argument="${argument} -c ${comp_type}" |
166 | 220 | fi |
221 | + if [[ -n ${kernel} ]]; then | |
222 | + argument="${argument} -k ${kernel}" | |
223 | + fi | |
167 | 224 | if [[ -n ${password} ]]; then |
168 | 225 | argument="${argument} -p ${password}" |
169 | 226 | fi |
@@ -172,9 +229,11 @@ function generate_argument () { | ||
172 | 229 | # 上の質問の関数を実行 |
173 | 230 | function ask () { |
174 | 231 | enable_plymouth |
232 | + select_kernel | |
175 | 233 | select_comp_type |
176 | 234 | set_comp_option |
177 | 235 | set_password |
236 | + lastcheck | |
178 | 237 | } |
179 | 238 | |
180 | 239 | # 将来的なビルド用の確認(このスクリプトは将来的には自動でcloneしビルドすることを目指しています。) |
@@ -182,6 +241,7 @@ function lastcheck () { | ||
182 | 241 | echo "以下の設定でビルドを開始します。" |
183 | 242 | echo |
184 | 243 | echo " Plymouth : ${plymouth}" |
244 | + echo " kernel : ${kernel}" | |
185 | 245 | echo " Compression method : ${comp_type}" |
186 | 246 | echo "Compression options : ${comp_option}" |
187 | 247 | echo " Password : ${password}" |
@@ -196,11 +256,14 @@ function lastcheck () { | ||
196 | 256 | esac |
197 | 257 | } |
198 | 258 | |
259 | +function start_build () { | |
260 | + # build.shの引数を表示(デバッグ用) | |
261 | + # echo ${argument} | |
262 | + sudo ./build.sh ${argument} | |
263 | + make cleanup | |
264 | +} | |
199 | 265 | |
200 | 266 | # 関数を実行 |
201 | 267 | ask |
202 | -lastcheck | |
203 | 268 | generate_argument |
204 | - | |
205 | -# build.shの引数を表示(デバッグ用) | |
206 | -echo ${argument} | |
\ No newline at end of file | ||
269 | +start_build | |
\ No newline at end of file |