首页
学习
活动
专区
工具
TVP
发布
社区首页 >问答首页 >如何在Atom文本编辑器中使用正则表达式选择Ruby文件中的所有注释?

如何在Atom文本编辑器中使用正则表达式选择Ruby文件中的所有注释?
EN

Stack Overflow用户
提问于 2019-05-01 20:01:32
回答 1查看 58关注 0票数 -3

在Atom文本编辑器中可以用来只选择注释的正则表达式是什么?

代码语言:javascript
复制
puts "Hello, world!"
# The puts command displays the character string in the output screen.
puts "Goodbye, world!
EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2019-05-01 20:28:59

看起来你想要^[ \t]*#.+$

代码语言:javascript
复制
^        Start of string
[ \t]*   Any number of space or tabs
#        The # character
.+       At least one more character
$        end of line
票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/55935954

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档