Skip to content

Commit d73354e

Browse files
committed
Adding NetBeans configuration and updates to the README.md file.
1 parent a358dd8 commit d73354e

File tree

4 files changed

+48
-11
lines changed

4 files changed

+48
-11
lines changed

.gitignore

+2
Original file line numberDiff line numberDiff line change
@@ -1 +1,3 @@
11
/nbproject
2+
.DS_Store
3+
Thumbs.db

README.md

+11-11
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,23 @@
1-
# PSR formatting for NetBeans
1+
# PSR auto-formatting for NetBeans
22

3-
Provides import-able [NetBeans](https://netbeans.org/) configuration settings for PSR 1&2, Although NetBeans may not provide support for all of the formatting standards, where possible I have implemented them.
3+
Provides import-able configuration settings for PSR1/PSR2 standards. Although NetBeans does not provide automatic formatting support for all of the PSR1 and PSR2 standards (eg. refactoring class and method names), where possible I have implemented the new line, braces positioning, spaced tabs etc. When using the ```Source > Format``` function in NetBeans the PHP code will automatically be formatted to match PSR1/2 syntax format.
44

5-
Requirements
6-
------------
5+
## Requirements
76

87
* [NetBeans](https://netbeans.org/) (Tested and developed on v8.0.2 but should work fine on other versions too!)
98

10-
License
11-
-------
9+
## License
1210

1311
These configuration settings files are released under the [MIT license](LICENSE).
1412

15-
Support
16-
-------
13+
## Support
1714

1815
I am happy to provide support via. my personal email address, so if you need a hand drop me an email at: [mailto:ballen@bobbyallen.me](ballen@bobbyallen.me).
1916

20-
Installation
21-
------------
17+
## Installation
2218

23-
TBC
19+
TBC
20+
21+
## Preparing the source code for 'import'
22+
23+
In order to import the settings into NetBeans, compress the root directory of the ```src``` directory into a .ZIP file of which can then be used to import into NetBeans as shown below in the installation guide.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!DOCTYPE editor-preferences PUBLIC "-//NetBeans//DTD Editor Preferences 1.0//EN" "http://www.netbeans.org/dtds/EditorPreferences-1_0.dtd">
3+
<editor-preferences>
4+
<entry javaType="java.lang.String" name="blankLinesAfterClass" xml:space="preserve">
5+
<value><![CDATA[0]]></value>
6+
</entry>
7+
<entry javaType="java.lang.String" name="blankLinesAfterFunction" xml:space="preserve">
8+
<value><![CDATA[0]]></value>
9+
</entry>
10+
<entry javaType="java.lang.String" name="blankLinesAfterOpenPHPTag" xml:space="preserve">
11+
<value><![CDATA[0]]></value>
12+
</entry>
13+
<entry javaType="java.lang.String" name="blankLinesBeforeClosePHPTag" xml:space="preserve">
14+
<value><![CDATA[1]]></value>
15+
</entry>
16+
<entry javaType="java.lang.String" name="blankLinesBeforeNamespace" xml:space="preserve">
17+
<value><![CDATA[0]]></value>
18+
</entry>
19+
<entry javaType="java.lang.String" name="blankLinesBeforeUse" xml:space="preserve">
20+
<value><![CDATA[0]]></value>
21+
</entry>
22+
<entry javaType="java.lang.String" name="classDeclBracePlacement" xml:space="preserve">
23+
<value><![CDATA[NEW_LINE]]></value>
24+
</entry>
25+
<entry javaType="java.lang.String" name="continuationIndentSize" xml:space="preserve">
26+
<value><![CDATA[4]]></value>
27+
</entry>
28+
<entry javaType="java.lang.String" name="methodDeclBracePlacement" xml:space="preserve">
29+
<value><![CDATA[NEW_LINE]]></value>
30+
</entry>
31+
<entry javaType="java.lang.Integer" name="tab-size" xml:space="preserve">
32+
<value><![CDATA[4]]></value>
33+
</entry>
34+
</editor-preferences>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
OptionsDialog/Editor/MarkOccurrences/=text/x-php5

0 commit comments

Comments
 (0)