~noasakurajin/xapp/master

« back to all changes in this revision

Viewing changes to files/usr/bin/upload-system-info

  • Committer: Michael Webster
  • Author(s): worldofpeace
  • Date: 2020-01-08 03:33:00 UTC
  • Revision ID: git-v1:89ad087f22d9c5f3694585e6b5be5aa364de0e76
Install icons and scripts using meson options

With meson there's no point for a package to try to write to
'/' when there's built in options like 'bindir' and 'datadir' which
are the actual directories we want these files installed.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
#!/usr/bin/python3
2
 
 
3
 
import subprocess, os
4
 
 
5
 
try:
6
 
    inxi = subprocess.Popen(['inxi', '-Fxxrzc0'], stdout=subprocess.PIPE)
7
 
    pastebin = subprocess.Popen(['/usr/bin/pastebin'], stdin=inxi.stdout, stdout=subprocess.PIPE)
8
 
    inxi.stdout.close()
9
 
    output = pastebin.communicate()[0]
10
 
    output = output.split()[0] # if we have more than one URL, only use the first one
11
 
    pastebin.wait()
12
 
    subprocess.call(['xdg-open', output])
13
 
except Exception as e:
14
 
    print ("An error occurred while uploading the system information:")
15
 
    print (e)
16
 
    print ("Please make sure you're connected to the Internet.")