Skip to content

Commit

Permalink
Update README
Browse files Browse the repository at this point in the history
  • Loading branch information
litefeel committed Aug 13, 2017
1 parent d7e7ef6 commit 69e407a
Show file tree
Hide file tree
Showing 2 changed files with 99 additions and 54 deletions.
76 changes: 49 additions & 27 deletions README.md
@@ -1,46 +1,68 @@
ClassName
=============
# ClassName

[![Build Status](https://travis-ci.org/litefeel/Sublime-ClassName.svg?branch=master)](https://travis-ci.org/litefeel/Sublime-ClassName)
[![Build status](https://ci.appveyor.com/api/projects/status/40vjxtplhvw82aw8/branch/master?svg=true)](https://ci.appveyor.com/project/litefeel/sublime-ClassName/branch/master)
[![Coverage Status](https://coveralls.io/repos/github/litefeel/Sublime-ClassName/badge.svg?branch=master)](https://coveralls.io/github/litefeel/Sublime-ClassName?branch=master)
[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/litefeel/Sublime-ClassName/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/litefeel/Sublime-ClassName/?branch=master)
[![codecov](https://codecov.io/gh/litefeel/Sublime-ClassName/branch/master/graph/badge.svg)](https://codecov.io/gh/litefeel/Sublime-ClassName)
<a href="https://packagecontrol.io/packages/ClassName"><img src="https://packagecontrol.herokuapp.com/downloads/ClassName.svg"></a>
<a href="https://www.paypal.me/litefeel/5usd" title="Donate to this project using Paypal"><img src="https://img.shields.io/badge/paypal-donate-blue.svg" /></a>

ClassName is a tiny and simple plugin for [Sublime Text](http://www.sublimetext.com) .
It copy class full name and package path to clipboard.

Usage
============
Install it using [Sublime Package Control](http://wbond.net/sublime_packages/package_control).
### Installtion

1. Install it using [Sublime Package Control](https://packagecontrol.io/installation).
2. Run `Package Control: Install Package` command
3. find and install ClassName plugin.

The default key bindings are
- [ctrl+alt+c] : copy class full name of current file to clipboard.
### Usage

You can also call ClassName commands when right-clicking files in the side bar.
- Right click to copy class name and package path
- `Ctrl+Alt+C` to copy class name

Settings
==============
### Key Bindings

If you need you will be able to add the prefix and suffix of classname.
please modify the path by selecting
"Preferences->Package Settings->ClassName->Settings - User" in the menu.
Default Key Bindings:
~~~json5
[
{ "keys": ["ctrl+alt+c"], "command": "classname_copy" }
]
~~~

The default setting is:
Change key bindings via menu:
`Preferences > Package Settings > ClassName > Key Bindings`

{
// set this string as prefix of class name
"classname_prefix": "",
// set this string as namespace separator
"namespace_separator": ".",
// set this string as suffix of class name
"classname_suffix": ""
}
### Settings

IMPORTANT
==============
Default Settings:

1. How to find class full name.
An folder '`xxxx/src`' in sibe bar and an file '`xxxx/src/com/litefeel/MyClass.ext`', the file's class full name is '`com.litefeel.MyClass`'.
~~~json5
{
// set this string as prefix of class name
"classname_prefix": "",
// set this string as namespace separator
"namespace_separator": ".",
// set this string as suffix of class name
"classname_suffix": ""
}
~~~

Change setting via menu:
`Preferences > Package Settings > ClassName > Settings`

### Frequently Asked Questions

1. What is class full name?
If the path of a file in the sidebar is `src/com/litefeel/MyClass.lua`,
so the class full name is `com.litefeel.MyClass`.

2. What is package path?
If the path of a file in the sidebar is `src/com/litefeel/MyClass.lua`,
so the package path is `com.litefeel`.

### Related Links

homepage:<https://www.litefeel.com/sublime-classname/>
github:<https://github.com/litefeel/Sublime-ClassName/>
issues:<https://github.com/litefeel/Sublime-ClassName/issues>
77 changes: 50 additions & 27 deletions messages/install.txt
@@ -1,38 +1,61 @@
Sublime-ClassName
=============
sublime-ClassName is a tiny and simple plugin for [Sublime Text](http://www.sublimetext.com) .
# ClassName

ClassName is a tiny and simple plugin for [Sublime Text](http://www.sublimetext.com) .
It copy class full name and package path to clipboard.

Usage
============
Install it using [Sublime Package Control](http://wbond.net/sublime_packages/package_control).
### Installtion

1. Install it using [Sublime Package Control](https://packagecontrol.io/installation).
2. Run `Package Control: Install Package` command
3. find and install ClassName plugin.

### Usage

- Right click to copy class name and package path
- `Ctrl+Alt+C` to copy class name

### Key Bindings

Default Key Bindings:
~~~json5
[
{ "keys": ["ctrl+alt+c"], "command": "classname_copy" }
]
~~~

Change key bindings via menu:
`Preferences > Package Settings > ClassName > Key Bindings`

### Settings

The default key bindings are
- [ctrl+alt+c] : copy class full name of current file to clipboard.
Default Settings:

You can also call ClassName commands when right-clicking files in the side bar.
~~~json5
{
// set this string as prefix of class name
"classname_prefix": "",
// set this string as namespace separator
"namespace_separator": ".",
// set this string as suffix of class name
"classname_suffix": ""
}
~~~

Settings
==============
Change setting via menu:
`Preferences > Package Settings > ClassName > Settings`

If you need you will be able to add the prefix and suffix of classname.
please modify the path by selecting
"Preferences->Package Settings->ClassName->Settings - User" in the menu.
### Frequently Asked Questions

The default setting is:
1. What is class full name?
If the path of a file in the sidebar is `src/com/litefeel/MyClass.lua`,
so the class full name is `com.litefeel.MyClass`.

{
// set this string as prefix of class name
"classname_prefix": "",
// set this string as namespace separator
"namespace_separator": ".",
// set this string as suffix of class name
"classname_suffix": ""
}
2. What is package path?
If the path of a file in the sidebar is `src/com/litefeel/MyClass.lua`,
so the package path is `com.litefeel`.

IMPORTANT
==============
### Related Links

1. How to find class full name.
An folder '`xxxx/src`' in sibe bar and an file '`xxxx/src/com/litefeel/MyClass.ext`', the file's class full name is '`com.litefeel.MyClass`'.
homepage:<https://www.litefeel.com/sublime-classname/>
github:<https://github.com/litefeel/Sublime-ClassName/>
issues:<https://github.com/litefeel/Sublime-ClassName/issues>

0 comments on commit 69e407a

Please sign in to comment.