{"action":"created","issue":{"url":"https://api.github.com/repos/rfjakob/earlyoom/issues/7","labels_url":"https://api.github.com/repos/rfjakob/earlyoom/issues/7/labels{/name}","comments_url":"https://api.github.com/repos/rfjakob/earlyoom/issues/7/comments","events_url":"https://api.github.com/repos/rfjakob/earlyoom/issues/7/events","html_url":"https://github.com/rfjakob/earlyoom/issues/7","id":92136758,"number":7,"title":"Reduce badness of certain processes using regexp","user":{"login":"joeytwiddle","id":911799,"avatar_url":"https://avatars.githubusercontent.com/u/911799?v=3","gravatar_id":"","url":"https://api.github.com/users/joeytwiddle","html_url":"https://github.com/joeytwiddle","followers_url":"https://api.github.com/users/joeytwiddle/followers","following_url":"https://api.github.com/users/joeytwiddle/following{/other_user}","gists_url":"https://api.github.com/users/joeytwiddle/gists{/gist_id}","starred_url":"https://api.github.com/users/joeytwiddle/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/joeytwiddle/subscriptions","organizations_url":"https://api.github.com/users/joeytwiddle/orgs","repos_url":"https://api.github.com/users/joeytwiddle/repos","events_url":"https://api.github.com/users/joeytwiddle/events{/privacy}","received_events_url":"https://api.github.com/users/joeytwiddle/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-06-30T16:25:34Z","updated_at":"2015-06-30T17:16:25Z","closed_at":null,"body":"I found earlyoom was too often killing the main firefox process, or the main chrome process, when I would really rather it had killed just one or two of the chrome tabs I had open, instead of killing a whole browser session!\r\n\r\nMy approach to this has been to reduce the badness of processes matching a certain regexp.  I compare the regexp against the process cmdline, rather than just the process name, so that I can be kind to the main process, but not to tabs or extensions.  (I divide badness by 32.)\r\n\r\nI have merged this feature with your recent changes, but I have not been able to test it because of #5, so try this at your own risk!  https://github.com/joeytwiddle/earlyoom\r\n\r\nThe unmerged version has been tested, but it is based on your older code: https://github.com/joeytwiddle/earlyoom/tree/logging_usleep\r\n\r\nIt has been working for me, and I consider it almost vital (so that I don't lose my whole browser when I have 100 tabs open).  I hope you also like the idea, and will consider merging it in!  (I could create a PR.)\r\n\r\nHowever I am also interested in slightly reducing the badness of recently-created or running processes, e.g. divide it by up to 8.  (I would slightly prefer if earlyoom attacks chrome tabs I haven't used for a long time, and not tab groups I am using now.)  (I suspect recently started processes are much easier to detect in Linux than recently used.  ;) )"},"comment":{"url":"https://api.github.com/repos/rfjakob/earlyoom/issues/comments/117264157","html_url":"https://github.com/rfjakob/earlyoom/issues/7#issuecomment-117264157","issue_url":"https://api.github.com/repos/rfjakob/earlyoom/issues/7","id":117264157,"user":{"login":"rfjakob","id":286847,"avatar_url":"https://avatars.githubusercontent.com/u/286847?v=3","gravatar_id":"","url":"https://api.github.com/users/rfjakob","html_url":"https://github.com/rfjakob","followers_url":"https://api.github.com/users/rfjakob/followers","following_url":"https://api.github.com/users/rfjakob/following{/other_user}","gists_url":"https://api.github.com/users/rfjakob/gists{/gist_id}","starred_url":"https://api.github.com/users/rfjakob/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rfjakob/subscriptions","organizations_url":"https://api.github.com/users/rfjakob/orgs","repos_url":"https://api.github.com/users/rfjakob/repos","events_url":"https://api.github.com/users/rfjakob/events{/privacy}","received_events_url":"https://api.github.com/users/rfjakob/received_events","type":"User","site_admin":false},"created_at":"2015-06-30T17:16:25Z","updated_at":"2015-06-30T17:16:25Z","body":"I understand that you cant test v0.7 right now, will fix that one soon ;)\n"}}