On 2018-08-20 17:07, Akkana Peck wrote:
>> Thomas Jollans :
>>> Wonderful. Now why don't we all forget about hexdump and use xxd? ;-)
>
> Marko Rauhamaa writes:
>> Fedora:
>>
>>$ xxd
>>bash: xxd: command not found
>>$ hd
>>bash: hd: command not found
>>$ od -Ax -tx1z -v <<>
> Thomas Jollans :
> > Wonderful. Now why don't we all forget about hexdump and use xxd? ;-)
Marko Rauhamaa writes:
> Fedora:
>
>$ xxd
>bash: xxd: command not found
>$ hd
>bash: hd: command not found
>$ od -Ax -tx1z -v <<00 68 65 6c 6c 6f 0a
On 2018-08-20, Chris Angelico wrote:
> On Mon, Aug 20, 2018 at 12:01 PM, Grant Edwards
>> What do you mean "run it as hd"?
>>
[... Calling via 'hd' alias makes no difference ...]
> Your system is different from mine, then.
No doubt. :)
> rosuav@sikorsky:~$ ls -l $(which hd)
> lrwxrwxrwx 1 root
Thomas Jollans :
> On 2018-08-20 04:22, Chris Angelico wrote:
>> On Mon, Aug 20, 2018 at 12:01 PM, Grant Edwards
>> wrote:
>>> On 2018-08-20, Ben Bacarisse wrote:
It is if you run it as hd.
>>> What do you mean "run it as hd"?
>>> I don't have an "hd" in my path.
>> Your system is different
On 2018-08-20 04:22, Chris Angelico wrote:
> On Mon, Aug 20, 2018 at 12:01 PM, Grant Edwards
> wrote:
>> On 2018-08-20, Ben Bacarisse wrote:
>>> It is if you run it as hd.
>>
>> What do you mean "run it as hd"?
>>
>> I don't have an "hd" in my path.
>
> Your system is different from mine, then.
On Mon, Aug 20, 2018 at 12:01 PM, Grant Edwards
wrote:
> On 2018-08-20, Ben Bacarisse wrote:
>> Grant Edwards writes:
>>
>>> On 2018-08-20, Steven D'Aprano wrote:
On Mon, 20 Aug 2018 00:31:35 +, Steven D'Aprano wrote:
> When I write bytes to stdout, why are they reversed?
On 2018-08-20, Ben Bacarisse wrote:
> Grant Edwards writes:
>
>> On 2018-08-20, Steven D'Aprano wrote:
>>> On Mon, 20 Aug 2018 00:31:35 +, Steven D'Aprano wrote:
>>>
When I write bytes to stdout, why are they reversed?
>>>
>>> Answer: they aren't, use hexdump -C.
>>
>> One might think t
On Mon, Aug 20, 2018 at 11:31 AM, Grant Edwards
wrote:
> On 2018-08-20, Chris Angelico wrote:
>> On Mon, Aug 20, 2018 at 11:12 AM, Grant Edwards
>> wrote:
>>> On 2018-08-20, Steven D'Aprano wrote:
On Mon, 20 Aug 2018 00:31:35 +, Steven D'Aprano wrote:
> When I write bytes to st
Grant Edwards writes:
> On 2018-08-20, Steven D'Aprano wrote:
>> On Mon, 20 Aug 2018 00:31:35 +, Steven D'Aprano wrote:
>>
>>> When I write bytes to stdout, why are they reversed?
>>
>> Answer: they aren't, use hexdump -C.
>
> One might think that dumping out bytes in the correct order ought
On 2018-08-20, Chris Angelico wrote:
> On Mon, Aug 20, 2018 at 11:12 AM, Grant Edwards
> wrote:
>> On 2018-08-20, Steven D'Aprano wrote:
>>> On Mon, 20 Aug 2018 00:31:35 +, Steven D'Aprano wrote:
>>>
When I write bytes to stdout, why are they reversed?
>>>
>>> Answer: they aren't, use he
On Mon, Aug 20, 2018 at 11:12 AM, Grant Edwards
wrote:
> On 2018-08-20, Steven D'Aprano wrote:
>> On Mon, 20 Aug 2018 00:31:35 +, Steven D'Aprano wrote:
>>
>>> When I write bytes to stdout, why are they reversed?
>>
>> Answer: they aren't, use hexdump -C.
>
> One might think that dumping out
On 2018-08-20, Steven D'Aprano wrote:
> On Mon, 20 Aug 2018 00:31:35 +, Steven D'Aprano wrote:
>
>> When I write bytes to stdout, why are they reversed?
>
> Answer: they aren't, use hexdump -C.
One might think that dumping out bytes in the correct order ought to
be the default format for hexd
On Mon, 20 Aug 2018 00:31:35 +, Steven D'Aprano wrote:
> When I write bytes to stdout, why are they reversed?
Answer: they aren't, use hexdump -C.
Thanks to all replies!
--
Steven D'Aprano
"Ever since I learned about confirmation bias, I've been seeing
it everywhere." -- Jon Ronson
--
h
On 20Aug2018 00:31, Steven D'Aprano
wrote:
When I write bytes to stdout, why are they reversed?
[steve@ando ~]$ python2.7 -c "print('\xfd\x84\x04\x08')" | hexdump
000 84fd 0804 000a
005
[steve@ando ~]$ python3.5 -c "import sys; sys.stdout.buffer.write(b'\xfd
\x84\x04\x08\n')" | hexdum
On Mon, Aug 20, 2018 at 10:31 AM, Steven D'Aprano
wrote:
> When I write bytes to stdout, why are they reversed?
>
> [steve@ando ~]$ python2.7 -c "print('\xfd\x84\x04\x08')" | hexdump
> 000 84fd 0804 000a
> 005
>
> [steve@ando ~]$ python3.5 -c "import sys; sys.stdout.buffer.write(b'\xfd
> \
On 2018-08-20, Steven D'Aprano wrote:
> When I write bytes to stdout, why are they reversed?
>
> [steve@ando ~]$ python2.7 -c "print('\xfd\x84\x04\x08')" | hexdump
> 000 84fd 0804 000a
> 005
They aren't. You're being fooled by the default output format of
hexdump. By default, it displa
When I write bytes to stdout, why are they reversed?
[steve@ando ~]$ python2.7 -c "print('\xfd\x84\x04\x08')" | hexdump
000 84fd 0804 000a
005
[steve@ando ~]$ python3.5 -c "import sys; sys.stdout.buffer.write(b'\xfd
\x84\x04\x08\n')" | hexdump
000 84fd 0804 000a
005
--
Steven
17 matches
Mail list logo