Merge pull request #36410 from tiramiseb/gnome-shell-extension-system-monitor

gnomeExtensions.system-monitor: fix this package and upgrade to v33
This commit is contained in:
Michael Raskin 2018-03-28 09:59:33 +00:00 committed by GitHub
commit 52f9d29d9a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 41 additions and 6 deletions

View file

@ -1,18 +1,28 @@
{ stdenv, fetchFromGitHub, glib }:
{ config, stdenv, substituteAll, fetchFromGitHub, glib, glib_networking, libgtop, pkgs }:
stdenv.mkDerivation rec {
name = "gnome-shell-system-monitor-${version}";
version = "8b31f070e9e59109d729661ced313d6a63e31787";
version = "33";
src = fetchFromGitHub {
owner = "paradoxxxzero";
repo = "gnome-shell-system-monitor-applet";
rev = version;
sha256 = "0fm5zb6qp53jjy2mnkb8ybxygzjwpb314giiq0ywq87hhrpch8m3";
rev = "v${version}";
sha256 = "0abqaanl5r26x8f0mm0jgrjsr86hcx7mk75dx5c3zz7csw4nclkk";
};
buildInputs = [
glib
glib_networking
libgtop
];
patches = [
(substituteAll {
src = ./paths_and_nonexisting_dirs.patch;
gtop_path = "${libgtop}/lib/girepository-1.0";
glib_net_path = "${glib_networking}/lib/girepository-1.0";
})
];
buildPhase = ''
@ -20,7 +30,8 @@ stdenv.mkDerivation rec {
'';
installPhase = ''
cp -r ${uuid} $out
mkdir -p $out/share/gnome-shell/extensions
cp -r ${uuid} $out/share/gnome-shell/extensions
'';
uuid = "system-monitor@paradoxxx.zero.gmail.com";
@ -28,7 +39,7 @@ stdenv.mkDerivation rec {
meta = with stdenv.lib; {
description = "Display system informations in gnome shell status bar";
license = licenses.gpl3Plus;
maintainers = with maintainers; [ aneeshusa ];
maintainers = with maintainers; [ aneeshusa tiramiseb ];
homepage = https://github.com/paradoxxxzero/gnome-shell-system-monitor-applet;
};
}

View file

@ -0,0 +1,23 @@
diff --git a/system-monitor@paradoxxx.zero.gmail.com/extension.js b/system-monitor@paradoxxx.zero.gmail.com/extension.js
index b4b7f15..d139135 100644
--- a/system-monitor@paradoxxx.zero.gmail.com/extension.js
+++ b/system-monitor@paradoxxx.zero.gmail.com/extension.js
@@ -18,6 +18,9 @@
// Author: Florian Mounier aka paradoxxxzero
+imports.gi.GIRepository.Repository.prepend_search_path('@gtop_path@');
+imports.gi.GIRepository.Repository.prepend_search_path('@glib_net_path@');
+
/* Ugly. This is here so that we don't crash old libnm-glib based shells unnecessarily
* by loading the new libnm.so. Should go away eventually */
const libnm_glib = imports.gi.GIRepository.Repository.get_default().is_registered("NMClient", "1.0");
@@ -386,7 +389,7 @@ const smMountsMonitor = new Lang.Class({
connected: false,
_init: function () {
this._volumeMonitor = Gio.VolumeMonitor.get();
- let sys_mounts = ['/home', '/tmp', '/boot', '/usr', '/usr/local'];
+ let sys_mounts = ['/home', '/tmp', '/boot'];
this.base_mounts = ['/'];
sys_mounts.forEach(Lang.bind(this, function (sMount) {
if (this.is_sys_mount(sMount + '/')) {

View file

@ -19516,6 +19516,7 @@ with pkgs;
nohotcorner = callPackage ../desktops/gnome-3/extensions/nohotcorner { };
no-title-bar = callPackage ../desktops/gnome-3/extensions/no-title-bar { };
remove-dropdown-arrows = callPackage ../desktops/gnome-3/extensions/remove-dropdown-arrows { };
system-monitor = callPackage ../desktops/gnome-3/extensions/system-monitor { };
taskwhisperer = callPackage ../desktops/gnome-3/extensions/taskwhisperer { };
timepp = callPackage ../desktops/gnome-3/extensions/timepp { };
topicons-plus = callPackage ../desktops/gnome-3/extensions/topicons-plus { };