Showing posts with label Linux. Show all posts
Showing posts with label Linux. Show all posts

End of Line Matters for Shell Script in CICD Pipeline

End of Line Matters for Shell Script in CICD Pipeline

You may get an error or failed pipeline if the end of line of a shell script file is CRLF (\r\n) not LF (\n) 

LF

CRLF


In VS Code, you may convert the End of Line from CRLF to LF. Or you may change the default setting



Know How to Use the chmod Command on Linux in Two Minutes

Know How to Use the chmod Command on Linux in Two Minutes

  1. Understand permissions
    1. how to check ($ls -l)
    2. file (-)
    3. dir (d)
    4. read (r)
    5. write (w)
    6. execute (x)
  2. User types
    1. user (u)/group (g)/other (o)
  3. Understand operations
    1. + (add)
    2. - (remove)
    3. = (set equal)
  4. Numerical shorthand
    • The digits you can use and what they represent are listed here:
        • 0: (000) No permission.
        • 1: (001) Execute permission.
          2: (010) Write permission.
          3: (011) Write and execute permissions.
          4: (100) Read permission.
          5: (101) Read and execute permissions.
          6: (110) Read and write permissions.
          7: (111) Read, write, and execute permissions.
    1. Recursive (-R)
        • If we had wanted to include files in subdirectories, we could have used the -R (recursive) option.
    2. Examples
        • $ls -l






        • $chmod 777 chmod_test.txt


        • $chmod u-x chmod_test.txt

      Featured Posts

      SnowPro Badges and Certificates

      SnowPro Badges and Certificates Online Verification https://achieve.snowflake.com/profile/richardhou888/wallet

      Popular Posts Recommended