Skip to content

Commit

Permalink
Merge branch 'Antiz96:main' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
Delor3an91 authored Jan 18, 2025
2 parents b6c9a37 + 8e82be1 commit f894cee
Show file tree
Hide file tree
Showing 15 changed files with 43 additions and 21 deletions.
21 changes: 21 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,27 @@

All notable changes to this project will be documented in this file.

## [v3.5.0](https://github.com/Antiz96/arch-update/releases/tag/v3.5.0) - 2025-01-18

### Features

- Add support for the DiffProg option when using doas ([#295](https://github.com/Antiz96/arch-update/pull/295)) - ([0fa90ec](https://github.com/Antiz96/arch-update/commit/0fa90ecb8c56157025edbfaed589c92047335ac1)) by @l-pt

### Miscellaneous

- Update release workflow ([#294](https://github.com/Antiz96/arch-update/pull/294)) - ([ee4867b](https://github.com/Antiz96/arch-update/commit/ee4867bc2e427502fc092c65cebab6cc53766cb1)) by @Antiz96

## [v3.4.3](https://github.com/Antiz96/arch-update/releases/tag/v3.4.3) - 2025-01-17

### Fixes

- Update Author and Date tags parsing in news ([#292](https://github.com/Antiz96/arch-update/pull/292)) - ([96b9481](https://github.com/Antiz96/arch-update/commit/96b9481579195407be39796ea9401680b86e4d36)) by @qhorgues

### Miscellaneous

- Rename LIBDIR env var ([#293](https://github.com/Antiz96/arch-update/pull/293)) - ([6106880](https://github.com/Antiz96/arch-update/commit/610688020cb41f6732e7d872f0840af4fcb00b2c)) by @Antiz96
- Optimize news path parsing when listing Arch news ([#290](https://github.com/Antiz96/arch-update/pull/290)) - ([4b2f6c5](https://github.com/Antiz96/arch-update/commit/4b2f6c5702d76bb3f6694c66bd61af3af41370fa)) by @Antiz96

## [v3.4.2](https://github.com/Antiz96/arch-update/releases/tag/v3.4.2) - 2024-12-06

### Fixes
Expand Down
2 changes: 1 addition & 1 deletion README-fr.md
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@ Les options prises en charge sont :
- PrivilegeElevationCommand=[Cmd] # Commande à utiliser pour l'élévation de privilège. Les valeurs valides sont `sudo`, `doas` ou `run0`. Si cette option n'est pas spécifiée, Arch-Update utilisera la première commande disponible dans l'odre suivant : `sudo`, `doas` puis `run0`.
- KeepOldPackages=[Num] # Nombre d'anciennes versions de paquets à conserver dans le cache de pacman. La valeur par défaut est 3.
- KeepUninstalledPackages=[Num] # Nombre de versions de paquets désinstallés à conserver dans le cache de pacman. La valeur par défaut est 0.
- DiffProg=[Editeur] # Editeur à utiliser pour visualiser / editer les différences durant le traitement des fichiers pacnew. La valeur par défaut est la valeur de la variable d'environnement `$DIFFPROG` (ou `vimdiff` si `$DIFFPROG` n'est pas paramétrée). Notez qu'en raison de l'absence d'option pour préserver les variables d'environnement dans `doas`, cette option sera ignorée lors de l'utilisation de `doas` comme méthode d'élévation de privilèges.
- DiffProg=[Editeur] # Editeur à utiliser pour visualiser / editer les différences durant le traitement des fichiers pacnew. La valeur par défaut est la valeur de la variable d'environnement `$DIFFPROG` (ou `vimdiff` si `$DIFFPROG` n'est pas paramétrée).
- TrayIconStyle=[Style / Color] # Style à utiliser pour l'icône de l'applet systray. Les valeurs valides sont les variantes de style / couleur disponibles pour le set d'icône, listées ici : https://github.com/Antiz96/arch-update/tree/main/res/icons. La valeur par défaut est "light".
Les options sont sensibles à la casse, les majuscules doivent donc être respectées.
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@ The supported options are:
- PrivilegeElevationCommand=[Cmd] # Command to be used for privilege elevation. Valid values are `sudo`, `doas` or `run0`. If this option is not set, Arch-Update will use the first available command in the following order: `sudo`, `doas` then `run0`.
- KeepOldPackages=[Num] # Number of old packages' versions to keep in pacman's cache. Defaults to 3.
- KeepUninstalledPackages=[Num] # Number of uninstalled packages' versions to keep in pacman's cache. Defaults to 0.
- DiffProg=[Editor] # Editor to use to visualize / edit differences during the pacnew files processing. Defaults to the `$DIFFPROG` environment variable's value (or `vimdiff` if `$DIFFPROG` isn't set). Note that, due to the lack of option to preserve environment variable in `doas`, this option will be ignored when using `doas` as the privilege elevation method.
- DiffProg=[Editor] # Editor to use to visualize / edit differences during the pacnew files processing. Defaults to the `$DIFFPROG` environment variable's value (or `vimdiff` if `$DIFFPROG` isn't set).
- TrayIconStyle=[Style / Color] # Style to be used for the systray applet icon. Valid values are the available style / color variants for the icon set, listed in https://github.com/Antiz96/arch-update/tree/main/res/icons. Defaults to "light".
Options are case sensitive, so capital letters have to be respected.
Expand Down
3 changes: 1 addition & 2 deletions RELEASE.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,10 @@ git tag v${TAG} -u D33FAA16B937F3B2 -m "v${TAG}"
git push origin v${TAG}
```

- Create a release on GitHub, copy / paste release notes from the changelog and sign the auto-generated source tarball:
- Create a release on GitHub, download and sign the auto-generated source tarball:

```bash
cd ~/Downloads
curl https://github.com/Antiz96/arch-update/archive/refs/tags/v${TAG}.tar.gz -o arch-update-${TAG}.tar.gz
gpg --local-user D33FAA16B937F3B2 --armor --detach-sign arch-update-${TAG}.tar.gz
sha256sum arch-update-${TAG}.tar.gz > arch-update-${TAG}.tar.gz.sha256
gpg --local-user D33FAA16B937F3B2 --armor --detach-sign arch-update-${TAG}.tar.gz.sha256
Expand Down
2 changes: 1 addition & 1 deletion doc/man/arch-update.1
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH "ARCH-UPDATE" "1" "November 2024" "Arch-Update 3.4.2" "Arch-Update Manual"
.TH "ARCH-UPDATE" "1" "November 2024" "Arch-Update 3.5.0" "Arch-Update Manual"

.SH NAME
arch-update \- An update notifier & applier for Arch Linux that assists you with important pre / post update tasks.
Expand Down
4 changes: 2 additions & 2 deletions doc/man/arch-update.conf.5
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH "ARCH-UPDATE.CONF" "5" "November 2024" "Arch-Update 3.4.2" "Arch-Update Manual"
.TH "ARCH-UPDATE.CONF" "5" "November 2024" "Arch-Update 3.5.0" "Arch-Update Manual"

.SH NAME
arch-update.conf \- arch-update configuration file.
Expand Down Expand Up @@ -49,7 +49,7 @@ Number of uninstalled packages' versions to keep in pacman's cache. Defaults to

.TP
.B DiffProg=[Editor]
.RB "Editor to use to visualize / edit differences during the pacnew files processing. Defaults to the " "$DIFFPROG " "environment variable's value (or " "vimdiff " "if " "$DIFFPROG " "isn't set). Note that, due to the lack of option to preserve environment variable in " "doas " ", this option will be ignored when using " "doas " " as the privilege elevation method."
.RB "Editor to use to visualize / edit differences during the pacnew files processing. Defaults to the " "$DIFFPROG " "environment variable's value (or " "vimdiff " "if " "$DIFFPROG " "isn't set)."

.TP
.B TrayIconStyle=[Style / Color]
Expand Down
2 changes: 1 addition & 1 deletion doc/man/fr/arch-update.1
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH "ARCH-UPDATE" "1" "Novembre 2024" "Arch-Update 3.4.2" "Manuel de Arch-Update"
.TH "ARCH-UPDATE" "1" "Novembre 2024" "Arch-Update 3.5.0" "Manuel de Arch-Update"

.SH NAME
arch-update \- Un notificateur & applicateur de mises à jour pour Arch Linux qui vous assiste dans les tâches importantes d'avant / après mise à jour.
Expand Down
4 changes: 2 additions & 2 deletions doc/man/fr/arch-update.conf.5
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH "ARCH-UPDATE.CONF" "5" "Novembre 2024" "Arch-Update 3.4.2" "Manuel de Arch-Update"
.TH "ARCH-UPDATE.CONF" "5" "Novembre 2024" "Arch-Update 3.5.0" "Manuel de Arch-Update"

.SH NAME
arch-update.conf \- fichier de configuration pour arch-update.
Expand Down Expand Up @@ -49,7 +49,7 @@ Nombre de versions de paquets désinstallés à conserver dans le cache de pacma

.TP
.B DiffProg=[Editeur]
.RB "Editeur à utiliser pour visualiser / editer les différences durant le traitement des fichiers pacnew. La valeur par défaut est la valeur de la variable d'environnement " "$DIFFPROG " "(ou " "vimdiff " "si " "$DIFFPROG " "n'est pas paramétrée). Notez qu'en raison de l'absence d'option pour préserver les variables d'environnement dans " "doas " ", cette option sera ignorée lors de l'utilisation de " "doas " "comme méthode d'élévation de privilèges."
.RB "Editeur à utiliser pour visualiser / editer les différences durant le traitement des fichiers pacnew. La valeur par défaut est la valeur de la variable d'environnement " "$DIFFPROG " "(ou " "vimdiff " "si " "$DIFFPROG " "n'est pas paramétrée)."

.TP
.B TrayIconStyle=[Style / Color]
Expand Down
2 changes: 1 addition & 1 deletion po/arch-update.pot
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
# AUTHOR <EMAIL@ADDRESS>, YEAR
msgid ""
msgstr ""
"Project-Id-Version: Arch-Update 3.4.2\n"
"Project-Id-Version: Arch-Update 3.5.0\n"
"Report-Msgid-Bugs-To: https://github.com/Antiz96/arch-update/issues\n"
"POT-Creation-Date: 2024-03-17 16:22+0100\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
Expand Down
2 changes: 1 addition & 1 deletion po/fr.po
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
# Robin Candau <[email protected]>, 2024
msgid ""
msgstr ""
"Project-Id-Version: Arch-Update 3.4.2\n"
"Project-Id-Version: Arch-Update 3.5.0\n"
"Report-Msgid-Bugs-To: https://github.com/Antiz96/arch-update/issues\n"
"POT-Creation-Date: 2024-03-17 16:22+0100\n"
"PO-Revision-Date: 2024-05-09 09:30+0100\n"
Expand Down
4 changes: 2 additions & 2 deletions po/sv.po
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
# Luna Jernberg <[email protected]>, 2024
msgid ""
msgstr ""
"Project-Id-Version: Arch-Update 3.4.2\n"
"Project-Id-Version: Arch-Update 3.5.0\n"
"Report-Msgid-Bugs-To: https://github.com/Antiz96/arch-update/issues\n"
"POT-Creation-Date: 2024-03-17 16:22+0100\n"
"PO-Revision-Date: 2024-11-19 12:22+0100\n"
Expand All @@ -16,7 +16,7 @@ msgstr ""
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Generator: Poedit 3.4.2\n"
"X-Generator: Poedit 3.5.0\n"

#: src/lib/check.sh:39 src/lib/check.sh:42
#, sh-format
Expand Down
6 changes: 3 additions & 3 deletions src/arch-update.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@
# General variables
name="arch-update"
_name="Arch-Update"
version="3.4.2"
version="3.5.0"
option="${1}"

# Define the directory containing libraries
if [ -n "${TEST_LIBDIR}" ]; then # Used in bats test cases for `make test`
libdir="${TEST_LIBDIR}"
if [ -n "${ARCH_UPDATE_LIBDIR}" ]; then
libdir="${ARCH_UPDATE_LIBDIR}"
elif [ -d "${XDG_DATA_HOME}/${name}/lib" ]; then
libdir="${XDG_DATA_HOME}/${name}/lib"
elif [ -d "${HOME}/.local/share/${name}/lib" ]; then
Expand Down
2 changes: 2 additions & 0 deletions src/lib/common.sh
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,8 @@ if [ -n "${diff_prog}" ]; then
else
if [ "${su_cmd}" == "sudo" ]; then
diff_prog_opt=("DIFFPROG=${diff_prog}")
elif [ "${su_cmd}" == "doas" ]; then
diff_prog_opt=("env" "DIFFPROG=${diff_prog}")
elif [ "${su_cmd}" == "run0" ]; then
diff_prog_opt+=("--setenv=DIFFPROG=${diff_prog}")
fi
Expand Down
6 changes: 3 additions & 3 deletions src/lib/list_news.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ else
if [ -n "${show_news}" ]; then
# shellcheck disable=SC2154
news_titles=$(echo "${news}" | htmlq -a title a | grep ^"View:" | sed "s/View:\ //g" | head -"${news_num}")
mapfile -t news_dates < <(echo "${news}" | htmlq td | grep -v "class" | grep "[0-9]" | sed "s/<[^>]*>//g" | sed "s/\.//g" | head -"${news_num}" | xargs -I{} date -d "{}" "+%s")
mapfile -t news_dates < <(echo "${news}" | htmlq td | grep -v "class" | grep "[0-9]" | sed "s/<[^>]*>//g" | head -"${news_num}" | xargs -I{} date -d "{}" "+%s")

echo
main_msg "$(eval_gettext "Arch News:")"
Expand Down Expand Up @@ -77,8 +77,8 @@ else
echo
warning_msg "$(eval_gettext "Unable to retrieve the selected Arch News (HTTP error response or request timeout)\nPlease, read the selected Arch News at \${news_url} before updating your system")"
else
news_author=$(echo "${news_content}" | htmlq -t .article-info | cut -f5- -d " ")
news_date=$(echo "${news_content}" | htmlq -t .article-info | cut -f1,2,3 -d " ")
news_author=$(echo "${news_content}" | htmlq -t .article-info | cut -f3- -d " ")
news_date=$(echo "${news_content}" | htmlq -t .article-info | cut -f1 -d " ")
news_article=$(echo "${news_content}" | htmlq -t .article-content)
title_tag="$(eval_gettext "Title:")"
author_tag="$(eval_gettext "Author:")"
Expand Down
2 changes: 1 addition & 1 deletion test/case/basic_functions.bats
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
export TEST_LIBDIR="${PWD}/src/lib"
export ARCH_UPDATE_LIBDIR="${PWD}/src/lib"

@test "version" {
src/arch-update.sh --version
Expand Down

0 comments on commit f894cee

Please sign in to comment.