Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. hopwon

    Counting in hex

    Awesome! Thanks for this man it works exactly as i wanted. Saved me loads of work! Cheers
  2. hopwon

    Counting in hex

    I'm writing a script to create target and lun numbers for disks. The script needs to start with a number and count to 7 printing the count. Then reset the second number to 0 and increment the first number and print the results. It must be in hex too. e.g. 0A 00 0A 01 0A 02 .... 0A 07 0B 00 0B 01...
  3. hopwon

    redirect

    How about for file in `ls box*.dat` do xargs awk 'BEGIN{FS=","}{print $2, $3/2}' > $file.txt done
  4. hopwon

    Assigning various lines from input file to a variable

    Hi all, I have a file in the format: 14B 0 10 37 - this is going to be converted to hex 03B1 03B2 03B3 03B4 etc, I want to assign the first 4 lines each to a variable v1 v2 v3 v4 Then process the rest of the file using the variables to get the output map dev 03B1 to dir 14B:0, target=10...
  5. hopwon

    awk to calculate line numbers in hex

    Yupo Feherke that works! Thanks you've saved me about a weeks work!
  6. hopwon

    awk to calculate line numbers in hex

    Hi I need a script that will take a file, number each line in the file and then append the line number on the end of the file in hex. Ideally I want to be able to add a set increment for the number i.e. add 25 onto each line number: cat map_175_r2.txt|awk 'NR{ $0 $0=++b+24 };{print}'|pg This...

Part and Inventory Search

Back
Top