summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLars Wirzenius <liw@liw.fi>2019-01-23 09:34:12 +0200
committerLars Wirzenius <liw@liw.fi>2019-01-23 09:34:12 +0200
commit64fa50994b1e74e3ce72fe4702a6f6dcda7c8560 (patch)
tree3030928253a5091f2d7e798483d83e4579ef5bb3
downloadeffitool-64fa50994b1e74e3ce72fe4702a6f6dcda7c8560.tar.gz
Add: initial commit
-rw-r--r--README62
-rwxr-xr-xeffitool24
2 files changed, 86 insertions, 0 deletions
diff --git a/README b/README
new file mode 100644
index 0000000..de4a787
--- /dev/null
+++ b/README
@@ -0,0 +1,62 @@
+effitool - use effireg from the command line
+=============================================================================
+
+effitool is a command line tool to use the API of the effireg
+membership register for the Effi association.
+
+Installation
+-----------------------------------------------------------------------------
+
+effitool is a single-file Python3 program. Get a copy from anywhere,
+and run it.
+
+ ./effitool
+
+Configuration
+-----------------------------------------------------------------------------
+
+In order to access the API, effitool needs API client credentials.
+Specifically, it needs a client id and a client secret. These are
+stored in the `~/.config/effitool/credentials.conf` file, which is an
+INI format file:
+
+ [effi]
+ url = https://effi-reg.vm.liw.fi
+ client_id = tapani
+ client_secret = YOUWISH
+
+The file may specify credentials for any number of instances of the
+membership regiester. This is handy for the developers. If only one is
+specified, effitool will use it automatically. If more than one server
+is specified, the `--api` (`-a`) option is used to pick one.
+
+ ./effitool -a effi ...
+
+The list of known servers can be listed:
+
+ ./effitool list-servers
+
+Usage:
+-----------------------------------------------------------------------------
+
+To check the version of the membership register:
+
+ ./effitool version
+
+Legalese
+-----------------------------------------------------------------------------
+
+Copyright 2019 Lars Wirzenius
+
+This program is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program. If not, see <http://www.gnu.org/licenses/>.
diff --git a/effitool b/effitool
new file mode 100755
index 0000000..071cc7f
--- /dev/null
+++ b/effitool
@@ -0,0 +1,24 @@
+#!/usr/bin/env python3
+#
+# Copyright 2019 Lars Wirzenius
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+
+def main():
+ print('hello from effitool')
+
+
+if __name__ == '__main__':
+ main()