about summary refs log blame commit diff stats
path: root/LICENSE
blob: 67e22c37c3a994e66539612cb02de910eca91baa (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
pre { line-height: 125%; }
td.linenos .normal { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
span.linenos { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
td.linenos .special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
span.linenos.special { color: #000000; background-color: #ffffc0; padding-left:
MIT/X Consortium License

(C)opyright MMVI Anselm R. Garbe <garbeam at gmail dot com>
(C)opyright MMVI Sander van Dijk <a dot h dot vandijk at gmail dot com>

Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the 
Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in 
all copies or substantial portions of the Software. 

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL 
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 
DEALINGS IN THE SOFTWARE.
class="w"> (Set) Complete(aerc *widgets.Aerc, args []string) []string { return nil } func SetCore(aerc *widgets.Aerc, args []string) error { if len(args) != 3 { return errors.New("Usage: " + setUsage()) } config := aerc.Config() parameters := strings.Split(args[1], ".") if len(parameters) != 2 { return errors.New("Usage: " + setUsage()) } category := parameters[0] option := parameters[1] value := args[2] new_file := ini.Empty() section, err := new_file.NewSection(category) if err != nil { return nil } if _, err := section.NewKey(option, value); err != nil { return err } if err := config.LoadConfig(new_file); err != nil { return err } return nil } func (Set) Execute(aerc *widgets.Aerc, args []string) error { return SetCore(aerc, args) }