Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package nwg-look for openSUSE:Factory checked in at 2026-10-15 16:12:14 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/nwg-look (Old) and /work/SRC/openSUSE:Factory/.nwg-look.new.3698736 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "nwg-look" Thu Oct 15 16:12:14 2026 rev:7 rq:1384880 version:1.2.1 Changes: -------- --- /work/SRC/openSUSE:Factory/nwg-look/nwg-look.changes 2026-10-13 17:47:15.994146708 +0200 +++ /work/SRC/openSUSE:Factory/.nwg-look.new.3698736/nwg-look.changes 2026-10-15 16:12:15.524299770 +0200 @@ -1,0 +2,7 @@ +Thu Oct 15 04:40:08 UTC 2026 - Khang Lê <[email protected]> + +- Update to version 1.2.1: + * bump to 1.2.1 + * support missing sound.json file + +------------------------------------------------------------------- Old: ---- nwg-look-1.2.0.tar.gz New: ---- nwg-look-1.2.1.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ nwg-look.spec ++++++ --- /var/tmp/diff_new_pack.aypjDa/_old 2026-10-15 16:12:16.313332906 +0200 +++ /var/tmp/diff_new_pack.aypjDa/_new 2026-10-15 16:12:16.315332990 +0200 @@ -16,7 +16,7 @@ # Name: nwg-look -Version: 1.2.0 +Version: 1.2.1 Release: 0 Summary: GTK3 settings editor adapted to work in sway/wlroots environment License: MIT ++++++ _service ++++++ --- /var/tmp/diff_new_pack.aypjDa/_old 2026-10-15 16:12:16.355334670 +0200 +++ /var/tmp/diff_new_pack.aypjDa/_new 2026-10-15 16:12:16.359334838 +0200 @@ -3,7 +3,7 @@ <param name="url">https://github.com/nwg-piotr/nwg-look.git</param> <param name="scm">git</param> <param name="exclude">.git</param> - <param name="revision">v1.2.0</param> + <param name="revision">v1.2.1</param> <param name="versionformat">@PARENT_TAG@</param> <param name="changesgenerate">enable</param> <param name="versionrewrite-pattern">v(.*)</param> ++++++ _servicedata ++++++ --- /var/tmp/diff_new_pack.aypjDa/_old 2026-10-15 16:12:16.389336098 +0200 +++ /var/tmp/diff_new_pack.aypjDa/_new 2026-10-15 16:12:16.392336224 +0200 @@ -1,6 +1,6 @@ <servicedata> <service name="tar_scm"> <param name="url">https://github.com/nwg-piotr/nwg-look.git</param> - <param name="changesrevision">a45feeaf617a46bb47dbeb69240bcde35bf15f6e</param></service></servicedata> + <param name="changesrevision">b9cc3e6b85fcb0aa04c1e66f092ebbca7e245b7f</param></service></servicedata> (No newline at EOF) ++++++ nwg-look-1.2.0.tar.gz -> nwg-look-1.2.1.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/nwg-look-1.2.0/langs/en_US.json new/nwg-look-1.2.1/langs/en_US.json --- old/nwg-look-1.2.0/langs/en_US.json 2026-10-13 01:42:30.000000000 +0200 +++ new/nwg-look-1.2.1/langs/en_US.json 2026-10-14 21:27:46.000000000 +0200 @@ -50,6 +50,7 @@ "slight": "Slight", "small": "Small", "sound-effects": "Sound effects", + "sound-json-absent": "File /var/cache/nwg-hello/sound.json not found (requires nwg-hello installed)", "sound-module-note": "A GTK module, such as canberra-gtk-module, may need to be loaded for sounds to be played across applications", "sound-theme-preview": "Sound theme preview", "sounds": "Sounds", diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/nwg-look-1.2.0/langs/pl_PL.json new/nwg-look-1.2.1/langs/pl_PL.json --- old/nwg-look-1.2.0/langs/pl_PL.json 2026-10-13 01:42:30.000000000 +0200 +++ new/nwg-look-1.2.1/langs/pl_PL.json 2026-10-14 21:27:46.000000000 +0200 @@ -49,6 +49,7 @@ "slight": "Lekki", "small": "Mały", "sound-effects": "Efekty dźwiękowe", + "sound-json-absent": "Brak pliku /var/cache/nwg-hello/sound.json (wymaga instalacji nwg-hello)", "sound-module-note": "Moduł GTK jak canberra-gtk-module powinien być załadowany, by aplikacje mogły odtwarzać dźwięki", "sound-theme-preview": "Podgląd tematu dźwiękowego", "sounds": "Dźwięki", diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/nwg-look-1.2.0/main.go new/nwg-look-1.2.1/main.go --- old/nwg-look-1.2.0/main.go 2026-10-13 01:42:30.000000000 +0200 +++ new/nwg-look-1.2.1/main.go 2026-10-14 21:27:46.000000000 +0200 @@ -22,7 +22,7 @@ "github.com/gotk3/gotk3/gtk" ) -const version = "1.2.0" +const version = "1.2.1" var ( preferences programSettings @@ -53,6 +53,7 @@ ExportIndexTheme bool `json:"export-index-theme"` ExportXsettingsd bool `json:"export-xsettingsd"` ExportGtk4Symlinks bool `json:"export-gtk4-symlinks"` + ExportNwgHelloSoundConfig bool `json:"export-nwg-hello-sound-config"` FlatpakExportGTKThemeOverride bool `json:"flatpak-export-gtk-theme-override"` FlatpakExportIconThemeOverride bool `json:"flatpak-export-icon-theme-override"` FlatpakInstallCurrentGTKTheme bool `json:"flatpak-install-current-gtk-theme"` @@ -65,7 +66,7 @@ p.ExportIndexTheme = true p.ExportXsettingsd = true p.ExportGtk4Symlinks = true - + p.ExportNwgHelloSoundConfig = true p.FlatpakExportGTKThemeOverride = false p.FlatpakExportIconThemeOverride = false p.FlatpakInstallCurrentGTKTheme = false @@ -170,6 +171,11 @@ return g } +type nwgHelloSoundConfig struct { + GtkSoundThemeName string `json:"gtk-sound-theme-name"` + GtkEnableEventSounds bool `json:"gtk-enable-event-sounds"` +} + func displayThemes() { destroyContent() rowToFocus = nil @@ -360,6 +366,9 @@ } else { clearGtk4Symlinks() } + if preferences.ExportNwgHelloSoundConfig { + exportNwgHelloSoundConfig() + } } os.Exit(0) } @@ -388,6 +397,9 @@ linkGtk4Stuff() saveGtkIni4() } + if preferences.ExportNwgHelloSoundConfig { + exportNwgHelloSoundConfig() + } } os.Exit(0) } @@ -489,6 +501,9 @@ linkGtk4Stuff() saveGtkIni4() } + if preferences.ExportNwgHelloSoundConfig { + exportNwgHelloSoundConfig() + } if preferences.FlatpakExportGTKThemeOverride { overrideFlatpakGTKTheme() } else if flatpakAvailable() { diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/nwg-look-1.2.0/tools.go new/nwg-look-1.2.1/tools.go --- old/nwg-look-1.2.0/tools.go 2026-10-13 01:42:30.000000000 +0200 +++ new/nwg-look-1.2.1/tools.go 2026-10-14 21:27:46.000000000 +0200 @@ -28,6 +28,10 @@ func loadPreferences() { cH := configHome() preferencesFile := filepath.Join(cH, "/nwg-look/config") + + // Set defaults to avoid empty values + preferences = programSettingsNewWithDefaults() + if !pathExists(preferencesFile) { log.Infof("%s file not found, creating", preferencesFile) makeDir(filepath.Join(cH, "/nwg-look/")) @@ -1632,3 +1636,34 @@ os.Exit(1) return nil } + +func exportNwgHelloSoundConfig() { + cacheDir := "/var/cache/nwg-hello" + if pathExists(cacheDir) { + cfg := nwgHelloSoundConfig{ + GtkSoundThemeName: gsettings.soundTheme, + GtkEnableEventSounds: gsettings.eventSounds, + } + jsonData, err := json.MarshalIndent(cfg, "", " ") + if err != nil { + log.Warnf("Failed to marshal nwg-hello sound config: %s", err) + return + } + + soundFile := filepath.Join(cacheDir, "sound.json") + log.Infof(">>> Exporting %s", soundFile) + err = os.WriteFile(soundFile, jsonData, 0664) + if err != nil { + log.Warnf("Couldn't export %s: %s", soundFile, err) + } + } +} + +func isWritable(path string) bool { + file, err := os.OpenFile(path, os.O_WRONLY, 0) + if err != nil { + return false + } + file.Close() + return true +} diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/nwg-look-1.2.0/uicomponents.go new/nwg-look-1.2.1/uicomponents.go --- old/nwg-look-1.2.0/uicomponents.go 2026-10-13 01:42:30.000000000 +0200 +++ new/nwg-look-1.2.1/uicomponents.go 2026-10-14 21:27:46.000000000 +0200 @@ -830,6 +830,20 @@ g.Attach(btn, 1, row, 1, 1) row++ + cbHello, _ := gtk.CheckButtonNewWithLabel("/var/cache/nwg-hello/sound.json") + fileExists := pathExists("/var/cache/nwg-hello/sound.json") + cbHello.SetSensitive(fileExists) + if !fileExists { + cbHello.SetTooltipText(voc["sound-json-absent"]) + } else { + cbHello.SetActive(preferences.ExportNwgHelloSoundConfig) + } + cbHello.Connect("toggled", func() { + preferences.ExportNwgHelloSoundConfig = cbHello.GetActive() + }) + g.Attach(cbHello, 0, row, 1, 1) + row++ + if flatpakAvailable() { lbl2, _ := gtk.LabelNew("") lbl2.SetMarkup(fmt.Sprintf("<b>%s</b>", voc["flatpak-settings"])) ++++++ vendor.tar.gz ++++++
