
Security News
Follow-up and Clarification on Recent Malicious Ruby Gems Campaign
A clarification on our recent research investigating 60 malicious Ruby gems.
Ruby utility that shows syntax highlighted code in your browser
Synful is a command line utility that will render syntax highlighted source code in your browser. Simply indicate the file or directory path names with optional file extensions to include or exclude. Synful will generate a nice index and an entry for each file and it will serve up the content and launch you web browser to view it. Once the request has been served, the server will close down and exit. If you'd like to keep the server running so that you can make changes and hit refresh, there is an option to do that also. All syntax highlighting is made possible by the amazing Rouge library.
$ synful winr/bin/winr censive/lib/censive.rb
A more complicated example is:
synful -f -x spec,ru lib test /tmp/example.rb -- -test/boring-results.txt
This will keep synful
in the foreground (the -f
option) and will
exclude all files with the .spec
or .ru
extensions. It will also
include files from the lib/
and test/
directories as well as the
/tmp/example.rb
file. Even though the test/boring-results.txt
file
should be rendered, we have disabled it via the -
(minus sign or dash)
in front of its filename. Note that to use this type of negation, we
need to precede it with a "double-dash" --
to tell synful
that we
are done with the normal command options.
Install via rubygems
with:
gem install synful
$ synful -h
usage: synful [options] <paths ...> [--] <-paths_to_skip ...>
-b, --bypass Bypass (skip over) top comments (begin with "#") in files
-f, --foreground Stay in the foreground, allows more requests
-h, --help Show help and command usage
-i, --include <exts> Comma list of extensions to include (incompatible with -x)
-x, --exclude <exts> Comma list of extensions to exclude (incompatible with -i)
This software is licensed under terms of the MIT License.
FAQs
Unknown package
We found that synful demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
A clarification on our recent research investigating 60 malicious Ruby gems.
Security News
ESLint now supports parallel linting with a new --concurrency flag, delivering major speed gains and closing a 10-year-old feature request.
Research
/Security News
A malicious Go module posing as an SSH brute forcer exfiltrates stolen credentials to a Telegram bot controlled by a Russian-speaking threat actor.