You are not logged in.

#1 2018-09-09 17:47:07

soaringowl2145
Member
Registered: 2016-12-17
Posts: 49

My update script via Gnome Terminal no longer works

So I wrote a bash script to update my system with pacman -Syu when I press F3, it would open Gnome Terminal and then execute pacman -Syu.  I did a system upgrade recently and I think that may have broke this.

==============
Here is the error:

[soaringowl@archlinux ~]$ /home/soaringowl/.update
[sudo] password for soaringowl: 
# posix_spawn avoided (fd close requested) 
# Error constructing proxy for org.gnome.Terminal:/org/gnome/Terminal/Factory0: Error spawning command line “dbus-launch --autolaunch=330481751d2440819cf2563df1353171 --binary-syntax --close-stderr”: Child process exited with code 1
==> no candidate packages found for pruning

===============

Here is the update shell script:

#!/bin/bash

sudo gnome-terminal -- pacman -Syu
sudo paccache -r

exit 0

===============

Here is my pacman.log:

https://pastebin.com/x4DL3f6M

================

Here is the output of ls /var/cache/pacman/pkg:

https://pastebin.com/45mxpbA3

================

kernel version:

[soaringowl@archlinux ~]$ cat /proc/version
Linux version 4.18.6-arch1-1-ARCH (builduser@heftig-4211) (gcc version 8.2.1 20180831 (GCC)) #1 SMP PREEMPT Wed Sep 5 11:54:09 UTC 2018

================

Thanks!

Last edited by soaringowl2145 (2018-09-09 18:13:18)

Offline

#2 2018-09-09 17:52:38

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,520
Website

Re: My update script via Gnome Terminal no longer works

Please edit your post to add code tags.

You really shouldn't run the whole terminal as root, just run pacman with sudo.


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#3 2018-09-09 18:00:54

soaringowl2145
Member
Registered: 2016-12-17
Posts: 49

Re: My update script via Gnome Terminal no longer works

Trilby wrote:

Please edit your post to add code tags.

How do I do that?

Offline

#4 2018-09-09 18:10:24

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,426
Website

Re: My update script via Gnome Terminal no longer works

Click the BBCode link at the bottom left of every text box.


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#5 2018-09-09 18:14:27

soaringowl2145
Member
Registered: 2016-12-17
Posts: 49

Re: My update script via Gnome Terminal no longer works

Is it fine now?

Last edited by soaringowl2145 (2018-09-09 18:19:56)

Offline

#6 2018-09-09 20:56:06

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 25,384

Re: My update script via Gnome Terminal no longer works

Yes, thanks. As has been mentioned, don't run your terminal as root

Offline

Board footer

Powered by FluxBB