ABOUT ME

-

Today
-
Yesterday
-
Total
-
  • git 기본 명령어 - 파일 다루기
    git 2024. 4. 18. 11:28

    기본 명령어(파일 다루기)

    파일 보기

    • ls: list
    • ls -l: long list
    • ls -al: all + long (히든파일, 예: .abc.txt와 같이 점으로 시작하는 파일은 -a 옵션을 사용해야 보임)
    • ls -a: all
    • lls *.txt: 확장자가 txt인 파일

    파일 내용 보기

    • cat
    • more
    • less

    파일 조작

    • cp: 파일 복사
    • mv: 파일 이동
    • ln: 파일 숏컷 (심볼릭 링크)
    • file: 파일 속성 보기

    디렉토리 관리

    • mkdir: 디렉토리 만들기
    • rmdir: 빈 디렉토리 삭제
    • cd, cd -: 디렉토리 이동
    • ./../~: 디렉토리 구조

    기타 명령어

    • clear: 터미널 지우기
    • reboot, poweroff, shutdown: 시스템 종료

    파일 만들기

    • touch [option] [file]: 파일의 마지막 수정시간을 현재시간으로 바꾸거나, 해당 파일이 존재하지 않는 경우 0 byte 파일 생성
      • touch hello.txt
      • touch test1 test2 test3
      • touch .hello.txt

    'git' 카테고리의 다른 글

    github + hexo blog + next theme  (0) 2024.04.21
    conventional commits  (0) 2024.04.20
    wsl + github 사용하기 1  (0) 2024.04.20
    WSL ubuntu에서 git 사용하기  (1) 2024.04.19
    conventional commit summary  (0) 2024.04.19
Designed by Tistory.