Can I use DevSkim to detect and flag based not on file content but file name, file extension, existence or other file metadata?
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 1k
- Forks
- 131
- Avg merge
- 1m
- Merged PRs (30d)
- 1
Description
I am wondering if I can flag files based on file name or extension? And preferably in combination with other files. Example use-case:
The scan folder contains an '.exe' file. I want to flag that exe file with the warning that pre-build files should not be part of the repository as it makes it harder to audit and verify the source code.
Preferably in combination with other files or folders. Such as, only flag the .exe file when the scan directory also contains a .git folder (not unlikely and indicating it's a git repo).
Or flag any blob for that matter. Perhaps files without file extension.
Or on any other metadata like, binaries unsinged by a trusted certificate etc.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
The issue names no files, tests, or entry points. Start by locating DevSkim's rule and scanning entry points, then determine whether rules can inspect filenames, extensions, neighboring files, and metadata. Done should include a defined way to flag the requested .exe and repository-context cases, with behavior for unsupported metadata clarified.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp
- Domain
- devtools, security
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100