Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | ||
6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 | 14 | 15 | 16 | 17 | 18 | 19 |
20 | 21 | 22 | 23 | 24 | 25 | 26 |
27 | 28 | 29 | 30 |
Tags
- spring mapper
- spring @mapper
- Transactions Propagation Option
- 자바버그수정
- Vue
- mapper annotationo
- spring JPA DB multi Connection
- vuecomponent
- JPA DB Connection 다중
- @Builder @NoArgsConstructor
- Spring JPA Specification
- repository annotation
- JAVA Exception 종류
- 도커 logs
- doker logs tail
- Spring
- docker 로그
- spring repository
- vueslot
- JpaRepository update
- 도커 로그 확인
- NoArgsConstructor
- spring JPA DB Connection
- CrudRepository update
- JPA DB 다중 Connection
- spring mapper annotation
- AllArgsConstructor
- 도커 컨테이너 로그
- Data Annotation
- spring DB Connection
Archives
- Today
- Total
개발을 잘하고 싶은 개발자
[Linux] 리눅스 파일의 글자 수를 알고 싶어 wc 본문
wc 명령어란?
word count의 줄임말은 w(orld)c(ount)는 글자 수 외에도
파일의 바이트, 문자, 단어, 줄 라인을 알려주는 유용한 명령어이다
1. 파일의 바이트 수를 알려줘
wc -c [파일명]
$cat text.txt
a
b
1
&
--
테스트
$wc -c text.txt
26 text.txt
2. 문자들의 수를 알려줘
$cat text.txt
a
b
1
&
테스트
$wc -m text.txt
12 text.txt
3. 몇 줄인지 알려줘
$cat text.txt
a
b
1
&
테스트
$wc -l text.txt
5 text.txt
4. 이 파일에는 몇 개의 단어가 있어?
(공백도 하나의 단어로 처리)
$cat text.txt
a
b
12 3
&
테스트
$wc -w text.txt
7 text.txt
참고 https://twpower.github.io/193-print-num-of-bytes-characters-words-lines-using-wc
'Linux' 카테고리의 다른 글
[Linux] awk 명령어란? (0) | 2021.07.31 |
---|