aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/docs/mutual_friends.md
diff options
context:
space:
mode:
authorEgor Tensin <Egor.Tensin@gmail.com>2016-06-20 02:54:52 +0300
committerEgor Tensin <Egor.Tensin@gmail.com>2016-06-20 02:54:52 +0300
commit5422a673b2b549c8d9e90ddd0271fe6850e3e2f2 (patch)
tree4285878be909d8ac9500399f082ceb49cfcb3ceb /docs/mutual_friends.md
parentimplement more user fields (diff)
downloadvk-scripts-5422a673b2b549c8d9e90ddd0271fe6850e3e2f2.tar.gz
vk-scripts-5422a673b2b549c8d9e90ddd0271fe6850e3e2f2.zip
mutual_friends.py: refactoring & interface update
Diffstat (limited to '')
-rw-r--r--docs/mutual_friends.md18
1 files changed, 7 insertions, 11 deletions
diff --git a/docs/mutual_friends.md b/docs/mutual_friends.md
index cc9396e..4e0e4b4 100644
--- a/docs/mutual_friends.md
+++ b/docs/mutual_friends.md
@@ -6,23 +6,21 @@ Learn who your ex and her new boyfriend are both friends with.
Usage
-----
-Run from the top-level directory using `python -m`.
-For example:
+Run from the top-level directory using `python -m`:
> python -m bin.mutual_friends -h
- usage: mutual_friends.py [-h] [--output-format {csv,json}] UID [UID ...]
+ usage: mutual_friends.py [-h] [--output-format {csv,json}] [--output OUTPUT]
+ UID [UID ...]
...
For example (using made up user IDs/"screen names"),
> python -m bin.mutual_friends john.doe jane.doe
- 89497105,John,Smith,john.smith
- 3698577,Jane,Smith,jane.smith
+ 89497105,John,Smith
+ 3698577,Jane,Smith
In the example above, both "John Doe" and "Jane Doe" are friends with "John
Smith" and "Jane Smith", whose user IDs are 89497105 and 3698577 respectively.
-Their "screen names" (the part after "vk.com/" of their personal page URLs) are
-"john.smith" and "jane.smith".
The output format is CSV (comma-separated values) by default.
You can also get a JSON document:
@@ -32,14 +30,12 @@ You can also get a JSON document:
{
"uid": 89497105,
"first_name": "John",
- "last_name": "Smith",
- "screen_name": "john.smith"
+ "last_name": "Smith"
},
{
"uid": 3698577,
"first_name": "Jane",
- "last_name": "Smith",
- "screen_name": "jane.smith"
+ "last_name": "Smith"
}
]