Removes the WRITE AS command and updates the man page to reflect the change
This commit is contained in:
parent
57c4e05e13
commit
ba9a016dfd
14
bombadillo.1
14
bombadillo.1
|
@ -196,20 +196,8 @@ write [url]
|
|||
Writes data from a given url to a file. The file is named by the last component of the url path. If the last component is blank or \fI/\fP a default name will be used. The file saves to the folder set by the \fIsavelocation\fP setting. \fIw\fP can be entered rather than the full \fIwrite\fP.
|
||||
.TP
|
||||
.B
|
||||
write [link id]]
|
||||
write [link id]
|
||||
Writes data from a given link id in the current document to a file. The file is named by the last component of the url path. If the last component is blank or \fI/\fP a default name will be used. The file saves to the folder set by the \fIsavelocation\fP setting. \fIw\fP can be entered rather than the full \fIwrite\fP.
|
||||
.TP
|
||||
.B
|
||||
write . [filename\.\.\.]
|
||||
Writes the current document to a file. The file is named by the filename argument should should not include a leading \fI/\fP. The file saves to the folder set by the \fIsavelocation\fP setting. \fIw\fP can be entered rather than the full \fIwrite\fP.
|
||||
.TP
|
||||
.B
|
||||
write [url] [filename\.\.\.]
|
||||
Writes data from a given url to a file. The file is named by the filename argument should should not include a leading \fI/\fP. The file saves to the folder set by the \fIsavelocation\fP setting. \fIw\fP can be entered rather than the full \fIwrite\fP.
|
||||
.TP
|
||||
.B
|
||||
write [link id] [filename\.\.\.]
|
||||
Writes data from a given link id in the current document to a file. The file is named by the filename argument should should not include a leading \fI/\fP. The file saves to the folder set by the \fIsavelocation\fP setting. \fIw\fP can be entered rather than the full \fIwrite\fP.
|
||||
.SH FILES
|
||||
\fBbombadillo\fP keeps a hidden configuration file in a user's home directory. The file is a simplified ini file titled \fI.bombadillo.ini\fP. It is generated when a user first loads \fBbombadillo\fP and is updated with bookmarks and settings as a user adds them. The file can be directly edited, but it is best to use the SET command to update settings whenever possible. To return to the state of a fresh install, simply remove the file and a new one will be generated with the \fBbombadillo\fP defaults. On some systems an administrator may set the configuration file location to somewhere other than a user's home folder. If you do not see the file where you expect it, contact your system administrator.
|
||||
.SH SETTINGS
|
||||
|
|
14
client.go
14
client.go
|
@ -369,7 +369,7 @@ func (c *client) doCommand(action string, values []string) {
|
|||
|
||||
func (c *client) doCommandAs(action string, values []string) {
|
||||
if len(values) < 2 {
|
||||
c.SetMessage(fmt.Sprintf("Expected 1 argument, received %d", len(values)), true)
|
||||
c.SetMessage(fmt.Sprintf("Expected 2+ arguments, received %d", len(values)), true)
|
||||
c.DrawMessage()
|
||||
return
|
||||
}
|
||||
|
@ -400,17 +400,6 @@ func (c *client) doCommandAs(action string, values []string) {
|
|||
}
|
||||
case "SEARCH":
|
||||
c.search(strings.Join(values, " "), "", "")
|
||||
case "WRITE", "W":
|
||||
u, err := MakeUrl(values[0])
|
||||
if err != nil {
|
||||
c.SetMessage(err.Error(), true)
|
||||
c.DrawMessage()
|
||||
return
|
||||
}
|
||||
fileName := strings.Join(values[1:], "-")
|
||||
fileName = strings.Trim(fileName, " \t\r\n\a\f\v")
|
||||
c.saveFile(u, fileName)
|
||||
|
||||
case "SET", "S":
|
||||
if _, ok := c.Options[values[0]]; ok {
|
||||
val := strings.Join(values[1:], " ")
|
||||
|
@ -438,6 +427,7 @@ func (c *client) doCommandAs(action string, values []string) {
|
|||
return
|
||||
}
|
||||
c.SetMessage(fmt.Sprintf("Unknown command structure"), true)
|
||||
c.DrawMessage()
|
||||
}
|
||||
|
||||
func (c *client) doLinkCommandAs(action, target string, values []string) {
|
||||
|
|
Loading…
Reference in New Issue