ComposeGears / ComposeGears/Valkyrie

Allow to rename imported files using a regex pattern

Open
#301 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Kotlin
Stars
889
Forks
26
Avg merge
36m
Merged PRs (30d)
2

Description

This is a continuation of #47.

My idea is to allow the same kind of functionality that is currently present in the IDE by default to perform Search&Replace.

Check this workaround: We can replace every reference to a resource (which is named incorrectly in terms of Compose style guide) with a new exported vector using regexp:

Image

But as you can see, this doesn't work fully, as the regexp for changing the usage that considers all word boundaries / changing case etc would be very complex and long and would need to be changed for imports and private property accessors.

Instead, it would be best to have this feature in the plugin (and now the cli too?) so that the user can directly import icons and rename them as they please.

This would probably look similarly to the screenshot above with the addition of a case selector, at least in my mind.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Read issue #47 first, then compare the existing IDE Search & Replace behavior with the plugin and CLI import flows. Clarify whether regex renaming belongs in the plugin, CLI, or both, including case handling and references to imports and private property accessors; done means agreed behavior and tests for the supported rename cases.

Written by the indexing model from the issue text.

Assessment

Tech stack
kotlin
Domain
cli, developer-experience, tooling
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.