mirror of
https://github.com/Jguer/yay
synced 2024-08-31 05:39:29 +00:00
Wrap -Sp
Currently we do not handle -Sp, this leads to yay trying a proper install and failing. So instead pass it to pacman and exit. Ideally we would extend -Sp to include AUR packages but for now don't bother.
This commit is contained in:
parent
96532c0b27
commit
c4fec3dad0
2
cmd.go
2
cmd.go
|
@ -417,6 +417,8 @@ func handleSync() (err error) {
|
|||
}
|
||||
|
||||
err = syncSearch(targets)
|
||||
} else if cmdArgs.existsArg("p", "print", "print-format") {
|
||||
err = show(passToPacman(cmdArgs))
|
||||
} else if cmdArgs.existsArg("c", "clean") {
|
||||
err = syncClean(cmdArgs)
|
||||
} else if cmdArgs.existsArg("l", "list") {
|
||||
|
|
10
parser.go
10
parser.go
|
@ -122,10 +122,6 @@ func (parser *arguments) needRoot() bool {
|
|||
return false
|
||||
}
|
||||
|
||||
if parser.existsArg("p", "print") {
|
||||
return false
|
||||
}
|
||||
|
||||
switch parser.op {
|
||||
case "D", "database":
|
||||
if parser.existsArg("k", "check") {
|
||||
|
@ -145,6 +141,12 @@ func (parser *arguments) needRoot() bool {
|
|||
case "R", "remove":
|
||||
return true
|
||||
case "S", "sync":
|
||||
if parser.existsArg("y", "refresh") {
|
||||
return true
|
||||
}
|
||||
if parser.existsArg("p", "print", "print-format") {
|
||||
return false
|
||||
}
|
||||
if parser.existsArg("s", "search") {
|
||||
return false
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue