Showing posts with label for. Show all posts
Showing posts with label for. Show all posts

Wednesday, 24 July 2013

Clear CLI with 1000 blank lines

For when you really want older output way out of your way, e.g., debugging, copying/pasting.
  1. for i in {1..1000};do echo;done

Wednesday, 3 July 2013

bash: funky hostname expansion in for loop


  1. for host in myhosts-{2{2,{6..9}},3{2,5,{7..9}}}.mydomain.com
    1. do 
      1. echo $host
      2. echo "ssh $host cmd"
  2. done

Thursday, 16 May 2013

Double looping with bash

Neat:
  1. for ITEM in $(find /cassandra/data -type d -name snapshots)
    1. do for DIR in $(find ${ITEM} -maxdepth 1 -mindepth 1 -type d -mtime -1)
      1. do echo $ITEM $DIR
    2. done
  2. done

Interview questions: 2020-12

Terraform provider vs provisioner Load balancing Network Load Balancer vs Application Load Balancer  Networking Layer 1 vs Layer 4 haproxy u...