Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/leny/atom-string-looper
Change word case, number value and loop between keywords with the arrow of your keyboard.
https://github.com/leny/atom-string-looper
Last synced: 7 days ago
JSON representation
Change word case, number value and loop between keywords with the arrow of your keyboard.
- Host: GitHub
- URL: https://github.com/leny/atom-string-looper
- Owner: leny
- License: mit
- Created: 2014-10-28T21:13:57.000Z (about 10 years ago)
- Default Branch: master
- Last Pushed: 2016-01-27T16:41:40.000Z (almost 9 years ago)
- Last Synced: 2024-04-11T15:58:56.271Z (7 months ago)
- Language: CoffeeScript
- Size: 207 KB
- Stars: 3
- Watchers: 3
- Forks: 1
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE.md
Awesome Lists containing this project
README
# string-looper package
> Change word case, number value and loop between keywords with the arrows of your keyboard.
* * *
**Note:** this package is kinda like in beta: it works in most cases, but in some cases the results can be a little weird. Don't hesitate [creating an issue](https://github.com/leny/atom-string-looper/issues) when you find one.
* * *
## Keymaps
### Looping up
**On Mac OS X:** `alt-up`
**On Windows & Linux:** `alt-up`### Looping down
**On Mac OS X:** `alt-down`
**On Windows & Linux:** `alt-down`### Looping up at cursor
**On Mac OS X:** `cmd-alt-up`
**On Windows & Linux:** `cmd-alt-up`### Looping down at cursor
**On Mac OS X:** `cmd-alt-down`
**On Windows & Linux:** `cmd-alt-down`## Behaviour
When you trigger the command over a word, it will loop between `lowercase`, `uppercase` and `camelCase` (adding a uppercase letter at cursor position).
![Loop a word](https://raw.githubusercontent.com/leny/atom-string-looper/master/caps/word-looper.gif)
When you trigger the command over certain words, it will loop between numerous possible values, like `yes` and `no`.
![Loop an enum](https://raw.githubusercontent.com/leny/atom-string-looper/master/caps/enum-looper.gif)
The built-in enums are :
* yes, no
* true, false
* relative, absolute, fixed
* top, bottom
* left, right
* width, height
* margin, padding
* block, none, inline, inline-block
* h1, h2, h3, h4, h5, h6
* am, pm
* sun, mon, tue, wed, thu, fri, sat
* sunday, monday, tuesday, wednesday, thursday, friday, saturday
* jan, feb, mar, apr, may, jun, jul, aug, sep, oct, nov, dec
* TODO, DONE, FIXMEYou can also add your own enums by modifying your `~/.atom/config.cson` file, like this :
```
'string-looper':
'enums': [
[
'oui'
'non'
],
[
'am'
'pm'
]
]
```When you trigger the command over a number, it will increment/decrement it by `1`.
![Loop a number](https://raw.githubusercontent.com/leny/atom-string-looper/master/caps/number-looper.gif)
If you use the "(in|de)crement-at-cursor" command, it will increment/decrement it at the point of the cursor.
![Loop a number at the cursor](https://raw.githubusercontent.com/leny/atom-string-looper/master/caps/number-looper-at-cursor.gif)
* * *
## TODO
* [ ] Write complete atom specs
* [ ] Refactor number-loop code