๐Ÿ“ฆ helioloureiro / pact-get

๐Ÿ“„ utils.go ยท 17 lines
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17package main

import (
	"os/exec"
)

const (
	PACMAN string = "/usr/bin/pacman"
)

// Run a shell command and return result as any error raised
func ShellExec(command string, args ...string) (string, error) {
	output, err := exec.Command(command, args...).Output()
	return string(output), err

}