Skip to content

Commit 46586b1

Browse files
committed
Merge pull request #7 from adambullmer/namespace-correction
Fixes namespace issues from installing through package control channel
2 parents da0e438 + 6dc0035 commit 46586b1

File tree

5 files changed

+12
-22
lines changed

5 files changed

+12
-22
lines changed

DocblockrPython.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import sublime
22

3-
from sublime_docblockr_python.formatters.registry import populate_registry
3+
from .formatters.registry import populate_registry
44

55
plugin_is_loaded = False
66

README.md

Lines changed: 6 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -7,22 +7,12 @@ The main goal of this project is to help developer provide better documentation
77

88
Installation
99
------------
10-
**Manually**
11-
Until this project can get onto Package Control, the only way to install it is manually.
12-
You can add this repo to package control manually and install it that way
13-
14-
1. Open your command pallete and type `Package Control: Add Repository`
15-
1. Copy and paste the [github url](https://github.com/adambullmer/sublime_docblockr_python) into the input field at the bottom of Sublime Text and press `Enter`
16-
1. Ensure the status bar says it was successfully added.
17-
18-
19-
Now you can install it with package control.
20-
10+
**Package Control**
11+
Now you can install it with package control!
2112
1. Open your command pallete and type `Package Control: Install Package`.
22-
1. Find this project `sublime_docblockr_python` and press `Enter`.
23-
13+
1. Find this project `DocBlockr Python` and press `Enter`.
2414

25-
**Slightly More Manually**
15+
**Manually**
2616
Download the release and put it in your installed packages directory yourself
2717

2818
1. Go to the [Latest Release](https://github.com/adambullmer/sublime-docblockr-python/releases/latest) and download the `docblockr_python.sublime-package` file.
@@ -48,7 +38,7 @@ You can also override your user settings on a per project basis by editing your
4838
"formatter": "sphinx"
4939
},
5040
"folders": [
51-
//...
41+
// ...
5242
]
5343
}
5444
```
@@ -69,7 +59,7 @@ If you don't like the formatting styles above, or want to make your own style to
6959
All you will need to do is extend the [Base formatter](https://github.com/adambullmer/sublime-docblockr-python/blob/master/formatters/base.py#L32) class and write your formatter functions.
7060
If you're not sure about it, you can take a look at any of the other formatters in the `formatters` source dir and see how they did it.
7161
```py
72-
from sublime_docblockr_python.formatters.base import Base
62+
from DocBlockr_Python.formatters.base import Base
7363

7464

7565
class MyFormatter(Base):

commands.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
import sublime_plugin
1313
import re
1414

15-
from sublime_docblockr_python.formatters.utils import get_formatter, get_setting
16-
from sublime_docblockr_python.parsers.parser import get_parser
15+
from .formatters.utils import get_formatter, get_setting
16+
from .parsers.parser import get_parser
1717

1818
log = logging.getLogger(__name__)
1919

formatters/registry.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ def register(Cls):
2626

2727
def populate_registry():
2828
"""Imports the list of built in parsers and adds them to the registry."""
29-
from sublime_docblockr_python.formatters import (
29+
from . import (
3030
base,
3131
PEP0257,
3232
docblock,

formatters/utils.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
import sublime
33
import importlib
44

5-
from sublime_docblockr_python.formatters.registry import REGISTRY
5+
from .registry import REGISTRY
66

77
log = logging.getLogger(__name__)
88

@@ -23,7 +23,7 @@ def get_formatter(name):
2323

2424
if formatter is None:
2525
log.warning('Formatter {} doesn\'t exist. Defaulting to Base formatter.'.format(name))
26-
temp = importlib.import_module('sublime_docblockr_python.formatters.base')
26+
temp = importlib.import_module('DocBlockr_Python.formatters.base')
2727
formatter = getattr(temp, 'BaseFormatter')
2828

2929
return formatter

0 commit comments

Comments
 (0)