{"thread":{"id":"31381","subject":"(minor concern) git using the pager should not be a default","startedAt":"2012-08-29T16:02:06Z","lastAt":"2012-08-31T23:03:17Z","messageCount":8,"participants":["Emmanuel Michon","Junio C Hamano","dag@cray.com","Andreas Schwab","Jeff King"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"198044","messageId":"503E3CFE.1080603@sigmadesigns.com","threadId":"31381","inReplyTo":null,"subject":"(minor concern) git using the pager should not be a default","fromName":"Emmanuel Michon","fromEmail":"emmanuel_michon@sigmadesigns.com","sentAt":"2012-08-29T16:02:06Z","receivedAt":"2012-08-29T16:02:06Z","isPatch":false,"sender":{"key":"emmanuel_michon@sigmadesigns.com","avatar":null},"body":"Hello,\n\nI'm risking myself on this mailing list after looking for some advise on\nIRC. Basically I know about this previous attempt\nhttp://marc.info/?l=git&m=122955045415845&w=2 but my request has little\nto do with emacs.\n\nI believe UNIX recommends some rules in the «less is more» spirit when\ndesigning command line applications [basically listed here:\nhttp://en.wikipedia.org/wiki/Unix_philosophy].\n\nAs far as I understand those, stdin/out/err would be better left with\nminimum processing. Silent execution with $? = 0 is the best thing that\ncan happen.\n\nPer those rules, which I think apply to Linux apps, it would be\npreferrable if the *default* setup of git didn't fork a pager, didn't\nuse colors, didn't behave differently whether piped or not.\n\nOf course I would be the first to always call the tool with\ngit diff |less\nexcepted when I do git diff |diffstat\nor enjoy such options as command line or environment switches to git.\nwhen I want.\n\nSo the point is more about the appropriateness of pushing that special\nergonomy to all users, knowing it makes most users happy.\n\nIsn't the design principle superior to the wishes of the masses?\n\nThanks for reading,\nDon't laugh,\nKeep on the good work.\n\nSincerely yours,\n\ne.m.\n"},{"id":"198049","messageId":"7vligxwr97.fsf@alter.siamese.dyndns.org","threadId":"31381","inReplyTo":"503E3CFE.1080603@sigmadesigns.com","subject":"Re: (minor concern) git using the pager should not be a default","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2012-08-29T17:19:00Z","receivedAt":"2012-08-29T17:19:00Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Emmanuel Michon <emmanuel_michon@sigmadesigns.com> writes:\n\n> Isn't the design principle superior to the wishes of the masses?\n\nOnly when you are living an ideal fantasy land.\n"},{"id":"198052","messageId":"7vd329wpt0.fsf@alter.siamese.dyndns.org","threadId":"31381","inReplyTo":"503E3CFE.1080603@sigmadesigns.com","subject":"Re: (minor concern) git using the pager should not be a default","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2012-08-29T17:50:19Z","receivedAt":"2012-08-29T17:50:19Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Emmanuel Michon <emmanuel_michon@sigmadesigns.com> writes:\n\n> I believe UNIX recommends some rules in the «less is more» spirit when\n> designing command line applications [basically listed here:\n> http://en.wikipedia.org/wiki/Unix_philosophy].\n\nThat is exactly why our plumbing layer of commands (e.g. \"git\ndiff-tree\", \"git rev-list\") do not page by default for people who\nwant to go bare-metal Unix philosophy.\n\nIn other words, Porcelain (roughly speaking, those that page by\ndefault when their standard output is terminal), are not \"command\nline applications\"; they have a layer on top with a built-in UI.\n\nIf you follow Unix philosophy and want to combine tools each of\nwhich is designed to do one thing and one thing well, you would be\nusing the commands from the plumbing layer to write your scripts,\nand wouldn't have to raise that \"minor concern\" in the first place,\nas they do not page by default ;-).\n"},{"id":"198158","messageId":"nngligvdk0q.fsf@transit.us.cray.com","threadId":"31381","inReplyTo":"7vd329wpt0.fsf@alter.siamese.dyndns.org","subject":"Re: (minor concern) git using the pager should not be a default","fromName":"","fromEmail":"dag@cray.com","sentAt":"2012-08-31T17:54:45Z","receivedAt":"2012-08-31T17:54:45Z","isPatch":false,"sender":{"key":"dag@cray.com","avatar":null},"body":"Junio C Hamano <gitster@pobox.com> writes:\n\n> In other words, Porcelain (roughly speaking, those that page by\n> default when their standard output is terminal), are not \"command\n> line applications\"; they have a layer on top with a built-in UI.\n\nIs \"status\" considered a plumbing layer command?  Because I have often\nwondered why it does not use the pager by default.  I pipe it through\nless all the time and it's kind of annoying that it works differently\nthan everything else.\n\n                                -Dave\n"},{"id":"198161","messageId":"m2a9xblyqp.fsf@igel.home","threadId":"31381","inReplyTo":"nngligvdk0q.fsf@transit.us.cray.com","subject":"Re: (minor concern) git using the pager should not be a default","fromName":"Andreas Schwab","fromEmail":"schwab@linux-m68k.org","sentAt":"2012-08-31T18:09:34Z","receivedAt":"2012-08-31T18:09:34Z","isPatch":false,"sender":{"key":"schwab@linux-m68k.org","avatar":"https://avatars.githubusercontent.com/u/2175493?v=4"},"body":"<dag@cray.com> writes:\n\n> Is \"status\" considered a plumbing layer command?  Because I have often\n> wondered why it does not use the pager by default.  I pipe it through\n> less all the time and it's kind of annoying that it works differently\n> than everything else.\n\nI would be pretty annoyed if git status would page by default.\n\nAndreas.\n\n-- \nAndreas Schwab, schwab@linux-m68k.org\nGPG Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5\n\"And now for something completely different.\"\n"},{"id":"198164","messageId":"7vy5kunbig.fsf@alter.siamese.dyndns.org","threadId":"31381","inReplyTo":"nngligvdk0q.fsf@transit.us.cray.com","subject":"Re: (minor concern) git using the pager should not be a default","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2012-08-31T18:48:23Z","receivedAt":"2012-08-31T18:48:23Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"<dag@cray.com> writes:\n\n> Junio C Hamano <gitster@pobox.com> writes:\n>\n>> In other words, Porcelain (roughly speaking, those that page by\n>> default when their standard output is terminal), are not \"command\n>> line applications\"; they have a layer on top with a built-in UI.\n>\n> Is \"status\" considered a plumbing layer command?\n\nHave you asked \"git help git\" lately?\n"},{"id":"198171","messageId":"20120831214312.GB3008@sigill.intra.peff.net","threadId":"31381","inReplyTo":"m2a9xblyqp.fsf@igel.home","subject":"Re: (minor concern) git using the pager should not be a default","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2012-08-31T21:43:12Z","receivedAt":"2012-08-31T21:43:12Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Fri, Aug 31, 2012 at 08:09:34PM +0200, Andreas Schwab wrote:\n\n> <dag@cray.com> writes:\n> \n> > Is \"status\" considered a plumbing layer command?  Because I have often\n> > wondered why it does not use the pager by default.  I pipe it through\n> > less all the time and it's kind of annoying that it works differently\n> > than everything else.\n> \n> I would be pretty annoyed if git status would page by default.\n\nThis one has been debated for a while. People used to complain that it\ndid not page, and then we turned on the pager, and then people\ncomplained that it did page. I wrote 4e10738 (Allow per-command pager\nconfig, 2008-07-03) to help settle it, and now you can do:\n\n  git config pager.status true\n\nif you really want it. As of 9bad723 (allow command-specific pagers in\npager.<cmd>, 2010-11-17), you can even set it to an arbitrary pager for\neach git command.\n\nWith all those options, it's amazing that we can still have threads\nabout what should page. :)\n\n-Peff\n"},{"id":"198173","messageId":"nngd3267jgq.fsf@transit.us.cray.com","threadId":"31381","inReplyTo":"20120831214312.GB3008@sigill.intra.peff.net","subject":"Re: (minor concern) git using the pager should not be a default","fromName":"","fromEmail":"dag@cray.com","sentAt":"2012-08-31T23:03:17Z","receivedAt":"2012-08-31T23:03:17Z","isPatch":false,"sender":{"key":"dag@cray.com","avatar":null},"body":"Jeff King <peff@peff.net> writes:\n\n> if you really want it. As of 9bad723 (allow command-specific pagers in\n> pager.<cmd>, 2010-11-17), you can even set it to an arbitrary pager for\n> each git command.\n\nCool!\n\n> With all those options, it's amazing that we can still have threads\n> about what should page. :)\n\nWell to be fair, it's hard to know when to read the documentation again.\n:)\n\n                               -Dave\n"}]}