{"action":"created","issue":{"url":"https://api.github.com/repos/pcapriotti/optparse-applicative/issues/190","repository_url":"https://api.github.com/repos/pcapriotti/optparse-applicative","labels_url":"https://api.github.com/repos/pcapriotti/optparse-applicative/issues/190/labels{/name}","comments_url":"https://api.github.com/repos/pcapriotti/optparse-applicative/issues/190/comments","events_url":"https://api.github.com/repos/pcapriotti/optparse-applicative/issues/190/events","html_url":"https://github.com/pcapriotti/optparse-applicative/issues/190","id":136319909,"number":190,"title":"How to handle situation when no command is passed","user":{"login":"Heather","id":2656965,"avatar_url":"https://avatars.githubusercontent.com/u/2656965?v=3","gravatar_id":"","url":"https://api.github.com/users/Heather","html_url":"https://github.com/Heather","followers_url":"https://api.github.com/users/Heather/followers","following_url":"https://api.github.com/users/Heather/following{/other_user}","gists_url":"https://api.github.com/users/Heather/gists{/gist_id}","starred_url":"https://api.github.com/users/Heather/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Heather/subscriptions","organizations_url":"https://api.github.com/users/Heather/orgs","repos_url":"https://api.github.com/users/Heather/repos","events_url":"https://api.github.com/users/Heather/events{/privacy}","received_events_url":"https://api.github.com/users/Heather/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2016-02-25T08:45:42Z","updated_at":"2016-04-15T14:17:50Z","closed_at":null,"body":"I'm using arrows, here is code:\r\n\r\n``` haskell\r\nparser = runA $ proc () → do\r\n  opts ← asA commonOpts ⤙ ()\r\n  cmds ← (asA . hsubparser)\r\n      (  command \"foo\"      (info foo (progDesc \"...\"))\r\n      <> command \"bar\"      (info (pure Bar)  (progDesc \"...\"))\r\n      ) ⤙ ()\r\n  A _version ⋙ A helper ⤙ Args opts cmds\r\n\r\nrun ∷ Args → IO ()\r\nrun (Args _ Bar)  = bar\r\n...\r\n\r\nmain ∷ IO ()\r\nmain = execParser opts ≫= run\r\n  where opts = info parser (...)\r\n```\r\n\r\nnow I want to handle situation when no arguments is passed but I don't fully understand how can I do it there?"},"comment":{"url":"https://api.github.com/repos/pcapriotti/optparse-applicative/issues/comments/210479573","html_url":"https://github.com/pcapriotti/optparse-applicative/issues/190#issuecomment-210479573","issue_url":"https://api.github.com/repos/pcapriotti/optparse-applicative/issues/190","id":210479573,"user":{"login":"Heather","id":2656965,"avatar_url":"https://avatars.githubusercontent.com/u/2656965?v=3","gravatar_id":"","url":"https://api.github.com/users/Heather","html_url":"https://github.com/Heather","followers_url":"https://api.github.com/users/Heather/followers","following_url":"https://api.github.com/users/Heather/following{/other_user}","gists_url":"https://api.github.com/users/Heather/gists{/gist_id}","starred_url":"https://api.github.com/users/Heather/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Heather/subscriptions","organizations_url":"https://api.github.com/users/Heather/orgs","repos_url":"https://api.github.com/users/Heather/repos","events_url":"https://api.github.com/users/Heather/events{/privacy}","received_events_url":"https://api.github.com/users/Heather/received_events","type":"User","site_admin":false},"created_at":"2016-04-15T14:17:50Z","updated_at":"2016-04-15T14:17:50Z","body":"@HuwCampbell thanks! how can I add _help and _version to it?"}}