In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/02 Report--
This article introduces you how to use pss search code, the content is very detailed, interested friends can refer to, hope to be helpful to you.
Searching the code base is something developers do every day. The ability to navigate through the code base quickly, from modifying bug to learning new code, or seeing how to call an API, is a big help. Fortunately, we have special tools to search for code. Pss is one of the tools. Let's take a look at how to install and use it.
Install pss
Install pss on Fedora using the following command:
$dnf install pss
After installation, you can call pss on the terminal:
$pss
Calling pss without arguments or with the-h flag will output detailed instructions for use.
Use case
Now that you have installed pss, let's take a look at some examples.
$pss foo
This command simply searches for foo. You can also restrict pss to search for foo only in python files:
$pss foo-py
You can also search for bar in non-python files:
$pss bar-nopy
Also, pss supports most common source code file types, and to get a complete support list, execute:
$pss-help-types
You can also specify to ignore certain directories and not to search. By default, pss ignores directories such as .git, pycache,.metadata, and so on.
$pss foo-py-ignore-dir=dist
In addition, pss can display the context of the search results.
$pss-A 5 foo
The next five lines of the match are displayed.
$pss-B 5 foo
The first five lines of the matching result are displayed.
$pss-C 5 foo
Five lines before and after the matching result are displayed.
On how to use pss search code to share here, I hope the above content can be of some help to you, can learn more knowledge. If you think the article is good, you can share it for more people to see.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.