1. 파일 다운로드

  • 옵션 명령어 "-O" 추가해서 저장될 파일명 지정(디렉토리도 안써주면 현재 폴더에 저장됨)
  • 인증 필요한 사이트에서는 옵션명령어로 "--no-check-certificate" 추가 해주면 됨
$ wget "https://github.com/yoochangkim/SmartMirro_Project/blob/main/dataset.zip?raw=true" -O dataset.zip
$ wget --no-check-certificate "https://github.com/yoochangkim/SmartMirro_Project/blob/main/dataset.zip?raw=true" -O dataset.zip

2. 압축 풀기

  • unzip [파일명.zip] -d [폴더명]
$ unzip dataset.zip -d ./dataset

$ unzip --help
UnZip 6.00 of 20 April 2009, by Debian. Original by Info-ZIP.

Usage: unzip [-Z] [-opts[modifiers]] file[.zip] [list] [-x xlist] [-d exdir]
  Default action is to extract files in list, except those in xlist, to exdir;
  file[.zip] may be a wildcard.  -Z => ZipInfo mode ("unzip -Z" for usage).

  -p  extract files to pipe, no messages     -l  list files (short format)
  -f  freshen existing files, create none    -t  test compressed archive data
  -u  update files, create if necessary      -z  display archive comment only
  -v  list verbosely/show version info       -T  timestamp archive to latest
  -x  exclude files that follow (in xlist)   -d  extract files into exdir
modifiers:
  -n  never overwrite existing files         -q  quiet mode (-qq => quieter)
  -o  overwrite files WITHOUT prompting      -a  auto-convert any text files
  -j  junk paths (do not make directories)   -aa treat ALL files as text
  -U  use escapes for all non-ASCII Unicode  -UU ignore any Unicode fields
  -C  match filenames case-insensitively     -L  make (some) names lowercase
  -X  restore UID/GID info                   -V  retain VMS version numbers
  -K  keep setuid/setgid/tacky permissions   -M  pipe through "more" pager
See "unzip -hh" or unzip.txt for more help.  Examples:
  unzip data1 -x joe   => extract all files except joe from zipfile data1.zip
  unzip -p foo | more  => send contents of foo.zip via pipe into program more
  unzip -fo foo ReadMe => quietly replace existing ReadMe if archive file newer

[참고] 깃허브에 파일 올리기

  • 깃허브에 프로젝트 폴더 생성해서 압출 파일 올리기
  • 해당 파일 클릭후 View raw 로 되어있는부분 링크 주소 복사
  • (또는 파일 링크 경로 끝에 "?raw=true" 만 추가 해주면 됨)

[프로젝트 폴더 생성해서 압출파일 올리기]

 

[링크주소 복사]

 

'프로그래밍 기초 > 리눅스' 카테고리의 다른 글

apt와 apt-get의 차이점  (0) 2022.07.05
리눅스 시스템 사양 확인 명령어  (0) 2022.07.05

+ Recent posts