{"action":"created","issue":{"url":"https://api.github.com/repos/klaasb/passdmenu/issues/6","labels_url":"https://api.github.com/repos/klaasb/passdmenu/issues/6/labels{/name}","comments_url":"https://api.github.com/repos/klaasb/passdmenu/issues/6/comments","events_url":"https://api.github.com/repos/klaasb/passdmenu/issues/6/events","html_url":"https://github.com/klaasb/passdmenu/issues/6","id":100398446,"number":6,"title":"Extracting usernames from matched line","user":{"login":"pigmonkey","id":502635,"avatar_url":"https://avatars.githubusercontent.com/u/502635?v=3","gravatar_id":"","url":"https://api.github.com/users/pigmonkey","html_url":"https://github.com/pigmonkey","followers_url":"https://api.github.com/users/pigmonkey/followers","following_url":"https://api.github.com/users/pigmonkey/following{/other_user}","gists_url":"https://api.github.com/users/pigmonkey/gists{/gist_id}","starred_url":"https://api.github.com/users/pigmonkey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pigmonkey/subscriptions","organizations_url":"https://api.github.com/users/pigmonkey/orgs","repos_url":"https://api.github.com/users/pigmonkey/repos","events_url":"https://api.github.com/users/pigmonkey/events{/privacy}","received_events_url":"https://api.github.com/users/pigmonkey/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-08-11T20:13:53Z","updated_at":"2015-08-21T06:58:23Z","closed_at":null,"body":"In reply to your comment in the `get_user_pw()` function, I think it is probably better to split the line only at the first white space character.\r\n\r\nCurrently, if the username has a space in it, you're only returning the first \"word\" of it. You can use `maxsplit=1` to split at the first occurrence.\r\n\r\n```\r\n>>> 'login: john doe'.split()\r\n['login:', 'john', 'doe']\r\n>>> 'login: john doe'.split(maxsplit=1)\r\n['login:', 'john doe']\r\n```\r\n\r\n[passff](https://github.com/jvenant/passff) expects the login (and url) field names to be separated by a colon. I like that personally because it encourages me to format everything after the password on line 1 as YAML, which helps me keep entries clean and parsable. If you wanted to follow that convention you could just split at the first `:` and then strip leading/trailing white space, but I don't know if that's really any more useful than splitting at the first white space."},"comment":{"url":"https://api.github.com/repos/klaasb/passdmenu/issues/comments/133309028","html_url":"https://github.com/klaasb/passdmenu/issues/6#issuecomment-133309028","issue_url":"https://api.github.com/repos/klaasb/passdmenu/issues/6","id":133309028,"user":{"login":"klaasb","id":961344,"avatar_url":"https://avatars.githubusercontent.com/u/961344?v=3","gravatar_id":"","url":"https://api.github.com/users/klaasb","html_url":"https://github.com/klaasb","followers_url":"https://api.github.com/users/klaasb/followers","following_url":"https://api.github.com/users/klaasb/following{/other_user}","gists_url":"https://api.github.com/users/klaasb/gists{/gist_id}","starred_url":"https://api.github.com/users/klaasb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/klaasb/subscriptions","organizations_url":"https://api.github.com/users/klaasb/orgs","repos_url":"https://api.github.com/users/klaasb/repos","events_url":"https://api.github.com/users/klaasb/events{/privacy}","received_events_url":"https://api.github.com/users/klaasb/received_events","type":"User","site_admin":false},"created_at":"2015-08-21T06:58:23Z","updated_at":"2015-08-21T06:58:23Z","body":"It does sound like a better specification to me and if we'd use something like YAML, this can make other use cases for extracting info and acting on it simpler."}}