{"action":"created","issue":{"url":"https://api.github.com/repos/weechat/weechat/issues/997","repository_url":"https://api.github.com/repos/weechat/weechat","labels_url":"https://api.github.com/repos/weechat/weechat/issues/997/labels{/name}","comments_url":"https://api.github.com/repos/weechat/weechat/issues/997/comments","events_url":"https://api.github.com/repos/weechat/weechat/issues/997/events","html_url":"https://github.com/weechat/weechat/issues/997","id":230280707,"number":997,"title":"Add \"calc\" function for eval expressions","user":{"login":"squigglezworth","id":20311086,"avatar_url":"https://avatars3.githubusercontent.com/u/20311086?v=3","gravatar_id":"","url":"https://api.github.com/users/squigglezworth","html_url":"https://github.com/squigglezworth","followers_url":"https://api.github.com/users/squigglezworth/followers","following_url":"https://api.github.com/users/squigglezworth/following{/other_user}","gists_url":"https://api.github.com/users/squigglezworth/gists{/gist_id}","starred_url":"https://api.github.com/users/squigglezworth/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/squigglezworth/subscriptions","organizations_url":"https://api.github.com/users/squigglezworth/orgs","repos_url":"https://api.github.com/users/squigglezworth/repos","events_url":"https://api.github.com/users/squigglezworth/events{/privacy}","received_events_url":"https://api.github.com/users/squigglezworth/received_events","type":"User","site_admin":false},"labels":[{"id":83724885,"url":"https://api.github.com/repos/weechat/weechat/labels/enhancement","name":"enhancement","color":"409de5","default":true}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2017-05-22T04:15:28Z","updated_at":"2017-05-25T20:40:18Z","closed_at":null,"body":"This was already shortly discussed on IRC, but it would probably be best to have it here.\r\n\r\n\r\nA `${calc:<some expression>}` function that would take parse simple math formulas would be very handy\r\n\r\n`${calc:1+1} == 2`\r\n`${calc:(2+2)*2} == 8`"},"comment":{"url":"https://api.github.com/repos/weechat/weechat/issues/comments/304118006","html_url":"https://github.com/weechat/weechat/issues/997#issuecomment-304118006","issue_url":"https://api.github.com/repos/weechat/weechat/issues/997","id":304118006,"user":{"login":"squigglezworth","id":20311086,"avatar_url":"https://avatars3.githubusercontent.com/u/20311086?v=3","gravatar_id":"","url":"https://api.github.com/users/squigglezworth","html_url":"https://github.com/squigglezworth","followers_url":"https://api.github.com/users/squigglezworth/followers","following_url":"https://api.github.com/users/squigglezworth/following{/other_user}","gists_url":"https://api.github.com/users/squigglezworth/gists{/gist_id}","starred_url":"https://api.github.com/users/squigglezworth/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/squigglezworth/subscriptions","organizations_url":"https://api.github.com/users/squigglezworth/orgs","repos_url":"https://api.github.com/users/squigglezworth/repos","events_url":"https://api.github.com/users/squigglezworth/events{/privacy}","received_events_url":"https://api.github.com/users/squigglezworth/received_events","type":"User","site_admin":false},"created_at":"2017-05-25T20:40:15Z","updated_at":"2017-05-25T20:40:15Z","body":"Right, most use-cases would involve using another variable to do some\ncalculation. I should have included such examples.\n\nOn Thu, May 25, 2017 at 4:35 PM, Jos Ahrens <notifications@github.com>\nwrote:\n\n> Can you include some functions you feel this would be useful for? It seems\n> weird to have weechat do the maths rather than precompile it. I imagine\n> you're looking to do something like ${calc:60-${current_idle_time}} > 0\n> of sorts rather than just plain maths?\n>\n> —\n> You are receiving this because you authored the thread.\n> Reply to this email directly, view it on GitHub\n> <https://github.com/weechat/weechat/issues/997#issuecomment-304116870>,\n> or mute the thread\n> <https://github.com/notifications/unsubscribe-auth/ATXsLguuF89zDcMSUvRimfjkdg_LZoacks5r9eYkgaJpZM4Nh3PB>\n> .\n>\n"}}
{"actor":{"display_login":"squigglezworth"}}