/StringManipulation

IntelliJ plugin - https://plugins.jetbrains.com/plugin/2162

Primary LanguageJavaApache License 2.0Apache-2.0

String Manipulation Donate Version Downloads

IntelliJ plugin - https://plugins.jetbrains.com/plugin/2162


Sponsored by


Manage pull requests and conduct code reviews in your IDE with full source-tree context. Comment on any line, not just the diffs. Use jump-to-definition, your favorite keybindings, and code intelligence with more of your workflow.
Learn More



Main features

Provides actions for text manipulation:

Switch case:

  • Switch case (camelCase, kebab-lowercase, KEBAB-UPPERCASE, snake_case, SCREAMING_SNAKE_CASE, dot.case, words lowercase, First word capitalized, Words Capitalized, PascalCase)
  • Toggle: SCREAMING_SNAKE_CASE / camelCase
  • Toggle: snake_case / camelCase
  • Toggle: kebab-case / snake_case
  • Toggle: kebab-case / camelCase
  • Toggle: dot.case / camelCase
  • Toggle: PascalCase / camelCase
  • Toggle: lowercase words / camelCase
  • Toggle: First word capitalized / camelCase
  • Toggle: Capitalized Words / camelCase
  • To camelCase
  • To snake_case
  • To SCREAMING_SNAKE_CASE
  • Capitalize
  • To lower case
  • To UPPER CASE
  • Invert case
  • To Spring Boot System Env Variable
- 'Switch case' action can be customized, or new ones can be added in settings
- when nothing is selected, then either nothing or a whole line or a particular element is selected (report an issue if you find something to improve, each file type needs its own implementation to work flawlessly)

Un/Escape:

  • Un/Escape selected Java text
  • Un/Escape selected JavaScript text
  • Un/Escape selected C# text (regular, verbatim, interpolated)
  • Un/Escape selected HTML text
  • Un/Escape selected JSON text
  • Un/Escape selected XML text
  • Un/Escape selected SQL text
  • Un/Escape selected PHP text
  • Convert diacritics (accents) to ASCII
  • Convert non-ASCII to escaped Unicode
  • Convert escaped Unicode to String
  • Unicode normalization (NFD, NFC, NFKC, NFKD)

Encode/Decode:

  • Encode selected text to MD5 Hex
  • Encode selected text to SHA-1 Hex
  • Encode selected text to SHA-256 Hex
  • Encode selected text to SHA-512 Hex
  • Encode selected text to SHA3-256 Hex
  • Encode selected text to SHA3-512 Hex
  • De/Encode selected text as URL
  • De/Encode selected text to Base64
  • De/Encode selected text to Hex
  • ISO Timestamp to Epoch Milliseconds
  • Epoch Milliseconds to ISO Timestamp

Increment/Decrement:

  • Increment/decrement all numbers found.
  • Duplicate selection and increment/decrement all numbers found.
  • Create sequence - Keep first number, replace all other by incrementing
  • Increment duplicate numbers

Sort with natural order or Collator:

  • Reversing order of lines
  • Shuffle lines
  • Sort case-sensitive A-z
  • Sort case-sensitive z-A
  • Sort case-insensitive A-Z
  • Sort case-insensitive Z-A
  • Sort line length asc., desc.
  • Sort hexadecimally
  • Sort lines by subselection - only one selection/caret per line is handled
  • Sort tokens (delimited text)
  • Hierarchical sort
  • Shuffle Characters

Align:

  • Align carets/selections into a vertical line by inserting spaces
  • Format selected text to columns/table by a chosen separator/delimiter and sort by columns
  • Align text to left/center/right

Filter/Remove/Trim/Convert...:

  • Grep
  • Inverted Grep
  • Group by Grep - matched lines will be separated from not matched
  • Trim
  • Replace whitespaces with a single space char
  • Remove all spaces
  • Remove duplicate lines
  • Keep only duplicate lines
  • Remove empty lines
  • Remove all newlines
  • Minify JSON
  • Convert Between JSON and YAML

Other:

  • Reverse Letters
  • Swap Words
  • Swap Characters/Selections/Lines/Tokens
  • Wrap or shift double quotes to single quotes to backticks
  • Swap between double quotes and single quotes
  • Switch file path separators: Windows<->UNIX

Actions are available under Edit menu, or via the shortcut "alt M" and "alt shift M".
You can setup your own shortcuts for better usability.
Popup can be customized in File | Settings | Appearance & Behavior | Menus and Toolbars.

How to build and run

  1. Import the project into IDEA.

  2. In "File -> Project Structure" add an SDK. Choose IntelliJ Platform Plugin SDK, not JDK. It looks like this on Windows:

    And like this on a Mac:

  3. Choose the SDK root. Windows:

    Mac (select the /Applications/IntelliJ IDEA/):

  4. The project should build now. To run add the following run configuration if it's not added already:

  5. Now you should be able to run and debug the plugin in a separate IDEA instance.

  6. To package a distribution:

    (StringManipulation.zip will be generated in the project root, which you can install to the main IDE)


Privacy Notice: No personal data is collected at all


YourKit-Logo

YourKit supports open source projects with its full-featured Java Profiler. YourKit, LLC is the creator of YourKit Java Profiler and YourKit .NET Profiler, innovative and intelligent tools for profiling Java and .NET applications.