当前位置:网站首页>shell语句修改txt文件或者sh文件
shell语句修改txt文件或者sh文件
2022-08-05 02:22:00 【fK0pS】
shell语句修改txt文件或者sh文件
基本思路,使用正则表达式,找到目标,替换目标,保存文件
shell sed regular expression
regular expression
方案1:
runScSparkFilename="runScSpark.sh" sed -i "s/$search/$replace/" $filename
方案2:
$ cat /etc/syslog.conf | sed -n '/^[[:alpha:]]/p' authpriv.* /var/log/secure

边栏推荐
- RAID disk array
- 网络安全与元宇宙:找出薄弱环节
- C学生管理系统 据学号查找学生节点
- Live playback including PPT download | Build Online Deep Learning based on Flink & DeepRec
- 特殊矩阵的压缩存储
- 重新审视分布式系统:永远不会有完美的一致性方案……
- "Configuration" is a double-edged sword, it will take you to understand various configuration methods
- 力扣-二叉树的最大的深度
- Transfer Learning - Distant Domain Transfer Learning
- MySQL learning
猜你喜欢

2022了你还不会『低代码』?数据科学也能玩转Low-Code啦!

迁移学习——Joint Geometrical and Statistical Alignment for Visual Domain Adaptation

Advanced Numbers_Review_Chapter 1: Functions, Limits, Continuity

Programmer's list of sheep counting when insomnia | Daily anecdote

Unleashing the engine of technological innovation, Intel joins hands with ecological partners to promote the vigorous development of smart retail

Flink 1.15.1 集群搭建(StandaloneSession)

Hypervisor related knowledge points

Understand the recommendation system in one article: Recall 06: Two-tower model - model structure, training method, the recall model is a late fusion feature, and the sorting model is an early fusion

iNFTnews | What can NFTs bring to the sports industry and fans?

使用SuperMap iDesktopX数据迁移工具迁移ArcGIS数据
随机推荐
nodeJs--encapsulate routing
Utilities How to simply implement the quantization and compression of the model based on the OpenVINO POT tool
直播预告|30分钟快速入门!来看可信分布式AI链桨的架构设计
[Word] #() error occurs after Word formula is exported to PDF
The difference between a process in user mode and kernel mode [exclusive analysis]
Unleashing the engine of technological innovation, Intel joins hands with ecological partners to promote the vigorous development of smart retail
“配置”是把双刃剑,带你了解各种配置方法
[LeetCode Brush Questions] - Sum of Numbers topic (more topics to be added)
Optimizing the feed flow encountered obstacles, who helped Baidu break the "memory wall"?
SuperMap iDesktop.Net之布尔运算求交——修复含拓扑错误复杂模型
迁移学习——Joint Geometrical and Statistical Alignment for Visual Domain Adaptation
RAID disk array
Leetcode brushing questions - 22. Bracket generation
Hypervisor related knowledge points
亚马逊云科技携手中科创达为行业客户构建AIoT平台
蚁剑高级模块开发
Domain Driven Design - MDD
mysql树状结构查询问题
DAY23:命令执行&代码执行漏洞