作者热门文章
- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
这个问题在这里已经有了答案:
Circumvent the sed backreference limit \1 through \9
(5 个回答)
6年前关闭。
通常当你调用 sed 时,你可以调用 \1
引用第一个子匹配,即:
<something> | sed "s/<regex>\(<regex>\)<regex>/\1/"
\10
不起作用,因为它将被解释为
take submatch number one and add a zero behind it
.
最佳答案
这在 sed 中是不可能的。您将不得不使用不同的工具。
以下是关于 SO 的类似问题:
Circumvent the sed backreference limit \1 through \9 .
how to get 10th grouping value in sed?
关于regex - 引用第 10 次子赛,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11833104/
我是一名优秀的程序员,十分优秀!