14,115 reputation
11748
bio website shelfari.com/joseph-riad
location Cairo, Egypt
age 26
visits member for 1 year, 8 months
seen 3 hours ago
  • Electronic engineering major. (MSc. holder, PhD. candidate)
  • Doing Linux sysadmin stuff for lack of someone better.
  • Lover of books: technical, non-technical, literary,...

Reach me at joseph dOT samy DoT albert At Google's email service

profile for Joseph R. on Stack Exchange, a network of free, community-driven Q&A sites


1h
awarded  Generalist
4h
revised SED Command line question to find all occurances in a file
added 108 characters in body
5h
answered SED Command line question to find all occurances in a file
5h
revised reading a list of lines from a file writing output to a utility
added 273 characters in body
6h
answered reading a list of lines from a file writing output to a utility
1d
comment how to verify if root password changed correctly
What about people reading the process table via ps for example?
1d
comment Ubuntu Trusty Preseed Error
Did you check the log file it's referring to? /var/lib/insserv/run-20140722T1052.log (most probably it will still be /target/var/lig/insserv/...)
1d
comment Ubuntu Trusty Preseed Error
Sorry, I meant dpkg --configure sysv-rc.
1d
comment Ubuntu Trusty Preseed Error
What happens if you run chroot /target before running dpkg --reconfigure sysv-rc?
1d
revised Aggregate and group text file in bash
added 2040 characters in body
1d
comment Aggregate and group text file in bash
@Metallica I hope this explanation helps.
1d
revised Aggregate and group text file in bash
added 2040 characters in body
1d
comment Aggregate and group text file in bash
@Metallica You're quite welcome. Please don't forget to mark this answer 'Accepted' if it helped solve your problem.
1d
comment Aggregate and group text file in bash
@Qeole Not necessarily. I believe it would take considerable C programming experience to create a text processing tool that outperforms venerable tools like awk and perl. Even if that's not the case, I still think the design effort would outweigh the performance boost.
1d
comment Aggregate and group text file in bash
@Qeole You're right, I didn't notice that the OP mentioned a sorted file. My bad...
1d
comment Aggregate and group text file in bash
@Metallica Code updated and tested. Sorry for that. Perl scripts are not generally faster than GNU tools. It all depends on the algorithm. I suspect that regex matching and pattern space manipulation is what's slowing down the sed answer. On the other hand, the Perl script above uses hash tables which are known for their fast access time.
1d
revised Aggregate and group text file in bash
added 40 characters in body
1d
comment Aggregate and group text file in bash
This seems to assume that repeated AppIDs will be on consecutive lines. The OP didn't specify this.
1d
comment Aggregate and group text file in bash
@Metallica My bad. Semicolon added.
1d
revised Aggregate and group text file in bash
added 3 characters in body