GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
MOINMOINCLI(1) FreeBSD General Commands Manual MOINMOINCLI(1)

moinmoincli
edit existing MoinMoin wiki pages from a command line

moinmoincli [
-hquv
] [
-f textfile
] [
-n username
] [
-t target
] [
selector
]

moinmoincli is an interactive utility to edit existing MoinMoin wiki pages from a command line. moinmoincli was only tested with the FreeBSD Wiki which is using the MoinMoin engine. The FreeBSD Wiki address is also hard-coded into moinmoincli as the default web service the utility works with.
moinmoincli cannot create new wiki pages.
When moinmoincli is run in order to update a wiki page, a diff is presented to the user to confirm the changes. It is done by providing a comment describing the changes. Next, a summary and the action menu is displayed. The summary includes the username, the target, the comment, and the text file name. Actions that could be entered at the action menu prompt are described in the ACTION MENU subsection. Once the user confirms requested changes to be processed, the password prompt is presented to the user.

The options are as follows:
textfile, --file textfile
Point to the Ar textfile that is going to be sent to the server.
, --help
Show help.
username, --name username
Set the username to log in as.
, --quick
Activate the quick mode, which disables the action menu. As a result the changes will be uploaded once a comment is entered by the user.
target, --target target
Provide the name of the wiki page to be updated, e.g.: “/WiFi/80211ac”. A hyperlink is acceptable as well, e.g.: “https://wiki.freebsd.org/WiFi/80211ac”.
, --update
Download the contents of the target wiki page and put them into the
, --version
Show version.
selector
Run moinmoincli as preconfigured for a given selector.
Selectors are used if the select_target() function is defined in the configuration file (defaults are listed in the FILES section). A single selector is associated with a target and a textfile. As a result it is possible to use selectors to replace ‘moinmoincli -f ./80211ac.moin -t /WiFi/80211ac’ with ‘moinmoincli ac’ using an ac selector.

The following actions could be entered at the action menu prompt one action at a time:
, k
Confirm changes. The action menu will be closed and the changes uploaded to the server.
, a
Abort. Close moinmoincli immediately.
Mark changes as trivial so that subscribers to the modified wiki page are not notified.
Change the comment.
Show the diff.
Print the summary.

~/.moinmoincli.conf
The moinmoincli configuration file.
/tmp/moinmoincli-workdir
The location of temporary files.

Download the code of ‘https://wiki.freebsd.org/Community/Dogs’ and save it under ‘./dogs.moinmoin’:
moinmoincli --file ./dogs.moinmoin --target /Community/Dogs --update
Write ‘./sandbox.txt’ to ‘https://wiki.freebsd.org/WikiSandBox’ as ‘CharlieRoot’:
moinmoincli -n CharlieRoot -f ./sandbox.txt -t /WikiSandBox

  1. Configure ~/.moinmoincli.conf so that it is not necessary to specify the username, the text file name and the target website every time. Use selectors for that.
  2. Grab the latest version of the wiki page with a selector:
    moinmoincli -u selectorYouHaveConfigured
        
  3. Edit the text file.
  4. Push the changes over to the wiki server with:
    moinmoincli selectorYouHaveConfigured
        

# The username to use when logging in. 
name='CharlieRoot' 
 
# The password for the account. 
password='secret' 
 
# The default target It's used unless a selector or 
# the -t flag is used. 
target='/WikiSandBox' 
 
# The default textfile. 
textfile='/tmp/wiki.moin' 
 
# The select_target function, which defines the logic behind 
# selectors. 
select_target() { 
    case "$1" in 
        [wW]*) 
            target='/WiFi' 
            textfile="$HOME/wifi.moin" 
            ;; 
        *) 
            printf '%s0 "invalid selector '$1'" >&2 
            ;; 
    esac 
}

moinmoincli and its manual page was written by Mateusz Piotrowski <0mp@FreeBSD.org>.
August 17, 2018 FreeBSD 12.0-RELEASE

Search for    or go to Top of page |  Section 1 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.