Differences

This shows you the differences between two versions of the page.

Link to this comparison view

developer:create_project [2019/02/25 01:40]
127.0.0.1 external edit
developer:create_project [2019/06/04 01:20]
Line 1: Line 1:
-===== Creating a Splint Library ===== 
- 
-With Splint installed, open terminal at the root of a fresh code-igniter distribution and run the command 
-<code bash> 
-splint -c vendor_name/​package_name 
-</​code>​ 
- 
-> N.B vendor_name should be your set username at [[https://​splint.cynobit.com]] 
- 
-Replace the package_name with a name of your choice.\\ 
- 
-Next, create a splint.json file at the root of the newly created package to have the contents as below, given that as for example, your vendor name is ''​jonas''​ and your package name is ''​super-regex'';​ the path to create the file will be at ''​application/​splints/​jonas/​super-regex''​. 
- 
-<code json> 
-{ 
-  "​name":​ "​jonas/​super-regex",​ 
-  "​type":​ "​library",​ 
-  "​description":​ "A library that gives you regexps features on steroids.",​ 
-  "​tags":​ ["​regex",​ "​string"​],​ 
-  "​page":​ "​https://​github.com/​jonas/​super-regex",​ 
-  "​authors":​ [ 
-    { 
-      "​name":​ "Jonas Gutierez",​ 
-      "​email":​ "​jonas@gmail.com",​ 
-      "​page":​ "​about.me/​jonas",​ 
-      "​role":​ "​Developer"​ 
-    } 
-  ], 
-  "​php":​ ">​=5.3.0"​ 
-} 
-</​code>​ 
- 
-See [[developer:​splint_json|splint.json Docs]] for more about what you can do with the above file. 
- 
-> N.B The ''​splint.json''​ is necessary for the importation of the package into [[https://​splint.cynobit.com|Splint]] and must be created with the same letter case as shown. 
- 
-Next, initialize the newly created package as a git repository. (''​git init''​ must be run at the root of the newly created package.)\\ 
- 
-Next, go to [[https://​github.com|GitHub]] and create a repository (super-regex) for example. Then run the following command at the root of your newly created package in  ''​application/​splints/​jonas/​super-regex''​. Again, ''​jonas/​super-regex''​ is used for illustration.\\ 
- 
-<code bash> 
-git remote add origin https://​github.com/​jonas/​super-regex.git 
-git add * 
-git push -u origin master 
-</​code>​ 
- 
-> N.B how you handle this stage may differ. all that's required here is that you make your new splint package a repository. This is because only git repositories are allowed to be imported to splint. 
- 
-> N.B The Git repository must be public and must be on [[https://​github.com|GitHub]] 
- 
-Now go ahead and work on your library by creating models, views, helpers, libraries (php script(s) in ''​libraries''​ folder). ​ Remember that people have to use the libraries you develop, hence you need to document all about it in a ''​README.md''​ file.\\ 
- 
-> N.B ''​README.md''​ has to be ''​README.md''​ before Splint can see it. 
- 
-=== Publishing your Package on Splint === 
- 
-When you have finished developing your package, push all your commits on your master branch to GitHub. Then head on to the repository page of the package to make a  release. See [[https://​help.github.com/​en/​articles/​creating-releases|Creating GitHub releases]] on how to go about that.\\ 
- 
-Log into your account on [[https://​splint.cynobit.com|Splint] and go to the [[https://​splint.cynobit.com/​dashboard/​importPackage|Import Package]] page. you should see a page that looks like this.\\ 
- 
-{{ :​developer:​import_package.png | Splint Import Package}} 
- 
-Fill in the url of the git repository for the package in the given input field and click the ''​Import Package''​ button.\\ 
- 
-Once your package has been successfully imported, you can now install the package on any Code-Igniter distribution with the command ''​splint install jonas/​super-regex''​.\\ 
- 
-When you browse your list of packages, you'll see your newly imported package.\\ ​ 
- 
-when you click any package that you own on [[https://​splint.cynobit.com|Splint]],​ you'll see a control bar at the top of it's page that looks like this.\\ 
- 
-{{ :​developer:​package_control.png | Splint Package Control}}\\ 
- 
-Releases are what [[https://​splint.cynobit.com|Splint]] considers as package versions. If you made some changes to your package and would like to make it available for others to install, make another release ​ on [[https://​github.com|GitHub]] with your most recent changes and click the ''​update''​ button on the particular package page from [[https://​splint.cynobit.com|Splint]]. the update button looks like a Thunder sign as squared in green below.\\ 
- 
-{{ :​developer:​update_package.png |}}\\ 
- 
-This will quer it's original GitHub repository for new releases or tags. The next time someone runs ''​splint install jonas/​super-regex'',​ They'​ll get the most recent version of your package. 
- 
-=== Related Topics === 
-[[developer:​design_guides|Design Guides for Packages]] 
-