I'm new on shell scripting, and I need a help on this.
How could I create an output file delimited by variable strings? I mean, each variable has an specific length, for example:
variable1 (char 10)
variable2 (char 5)
variable3 (char 4)
variable4 (char 7)
variable5 (char 20)
variable6 (char 2)
...
The output file would be like this (each number is related to the content of the respective variable):
11111 22222333344444445555555 66
The content of next variable starts on the next position in the file, i.e., variable2
starts at 11th position, because the variable1
ends at 10th position. And the remaining space in the variable would be filled with blank spaces.