Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/szuecs/stringreplace
replaces a string without evaluating regexp for cases where sed is a pain to use
https://github.com/szuecs/stringreplace
Last synced: 4 days ago
JSON representation
replaces a string without evaluating regexp for cases where sed is a pain to use
- Host: GitHub
- URL: https://github.com/szuecs/stringreplace
- Owner: szuecs
- License: apache-2.0
- Created: 2022-09-22T18:44:54.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2022-09-22T18:56:46.000Z (about 2 years ago)
- Last Synced: 2024-10-31T10:12:42.147Z (about 2 months ago)
- Language: Go
- Size: 5.86 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
For everyone that doesn't want to deal with complex escape sed syntax
and wants to find and replace regular expressions in files.@ is the magic separator. Need something else? Create a PR or change
it in the file.```
% go build -o stringreplace main.go
% cat file1
([.])?(:[0-9]+)?)$")
% ./stringreplace '(:[@foo' file1
% cat file1
([.])?foo0-9]+)?)$")
```