The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 1,651 other followers

Archive for March 8th, 2019

sorting – Is there a Windows equivalent to the Unix uniq? – Super User

Posted by jpluimers on 2019/03/08

TL;DR:

  • Windows 10 has an undocumented /unique switch for sort
  • git for Windows ships with uniq (in a default x64 install, it is at C:\Program Files\Git\usr\bin\uniq.exe)

From [WayBack] sorting – Is there a Windows equivalent to the Unix uniq? – Super User

This works fine:

dir /s /b *0*.pas *1*.pas *2*.pas *3*.pas *4*.pas *5*.pas *6*.pas *7*.pas*8*.pas *9*.pas | sort /unique > pas-files-with-numeric-names.txt

I need remove duplicate lines from a text file, it is simple in Linux usingcat file.txt |sort | uniqwhen file.txt containsaaabbbaaacccIt will output aaabbbcccIs there a Windows

 

Posted in Development, Power User, Software Development, Windows, Windows Development | Leave a Comment »

sudo command doesn’t source /root/.bashrc – Unix & Linux Stack Exchange

Posted by jpluimers on 2019/03/08

TL;DR:

  • sudo -i is not an interactive logon to root
  • sudo -i bash is interactive and *does* execute /root/.bashrc

Source: [WayBack] sudo command doesn’t source /root/.bashrc – Unix & Linux Stack Exchange

–jeroen

Posted in *nix, *nix-tools, bash, Power User | Leave a Comment »

Reminder tip: Disable Wi-Fi during sleep to dramatically increase idle battery life on tablets and devices you don’t often use

Posted by jpluimers on 2019/03/08

I agree: [WayBack] It’s so obvious I hadn’t thought about this.. – Roderick Gadellaa – Google+.

[WayBackReminder tip: Disable Wi-Fi during sleep to dramatically increase idle battery life on tablets and devices you don’t often use

–jeroen

Posted in Android Devices, LifeHacker, Power User | Leave a Comment »

 
%d bloggers like this: