当前位置:网站首页>How to count the number of project code lines
How to count the number of project code lines
2022-07-07 08:56:00 【beibeix2015】
find . "(" -name "*" ")" -print | xargs wc -l
1、 Open the terminal , use cd command Navigate to the directory where the project is located .
2、 Call the following command to count the number of lines and total number of each source code file
(1) Including the empty line ( The code lines of each file will be listed ):
find . "(" -name "*.m" -or -name "*.mm" -or -name "*.c" -or -name "*.h" -or -name "*.xib" -or -name "*.pch" ")" -print | xargs wc -l
(2) Empty lines are not included ( Only the total number of rows will appear ):
find . "(" -name "*.m" -or -name "*.mm" -or -name "*.c" -or -name "*.h" -or -name "*.xib" -or -name "*.pch" ")" -print | xargs grep -v "^$"|wc -l
// If there is anything else . Suffix files can continue to be added, such as -or -name "*.java"
3、 enter
grep -v "^$"
Removing blank line comments is also included in the code line count
linux Detailed explanation of pipeline symbols
linux In command “|” Pipe symbol
边栏推荐
- Unity Shader入门精要初级篇(一)-- 基础光照笔记
- 测试人一定要会的技能:selenium的三种等待方式解读,清晰明了
- Unityshader introduction essentials personal summary -- Basic chapter (I)
- MAC OSX php dyld: Library not loaded: /usr/local/xxxx. dylib
- Common operating commands of Linux
- 对API接口或H5接口做签名认证
- Explain Huawei's application market in detail, and gradually reduce 32-bit package applications and strategies in 2022
- Category of IP address
- Un salaire annuel de 50 W Ali P8 vous montrera comment passer du test
- Selenium automation integration, eight years of testing experience, soft test engineer, an article to teach you
猜你喜欢
2022-07-06 Unity核心9——3D动画
Output all composite numbers between 6 and 1000
Unityshader introduction essentials personal summary -- Basic chapter (I)
[Yugong series] February 2022 U3D full stack class 007 - production and setting skybox resources
Greenplum 6.x reinitialization
About using CDN based on Kangle and EP panel
Lenovo hybrid cloud Lenovo xcloud: 4 major product lines +it service portal
Synchronized underlying principle, volatile keyword analysis
数字三角形模型 AcWing 1027. 方格取数
ncs成都新电面试经验
随机推荐
Nanjing commercial housing sales enabled electronic contracts, and Junzi sign assisted in the online signing and filing of housing transactions
Output a spiral matrix C language
The longest ascending subsequence model acwing 1017 Strange thief Kidd's glider
Platformization, a fulcrum of strong chain complementing chain
【Istio Network CRD VirtualService、Envoyfilter】
数字三角形模型 AcWing 275. 传纸条
模拟卷Leetcode【普通】1705. 吃苹果的最大数目
求有符号数的原码、反码和补码【C语言】
Simple use of Xray
How to realize sliding operation component in fast application
ChaosBlade:混沌工程简介(一)
LeetCode 736. LISP syntax parsing
阿里p8推荐,测试覆盖率工具—Jacoco,实用性极佳
MySQL partition explanation and operation statement
Skills that testers must know: Selenium's three waiting ways are interpreted clearly
Mountaineering team (DFS)
GoLand set goproxy
idea里使用module项目的一个bug
【ChaosBlade:根据标签删除POD、Pod 域名访问异常场景、Pod 文件系统 I/O 故障场景】
Category of IP address