You’ve probably read that two repositories have recently been published on the Wakanda GitHub page:
These repositories are meant to reference Wakanda studio extensions, as well as Web applications made with Wakanda, either by 4D or by members of the Wakanda community.
Most professional JavaScript developers today have a GitHub account on which they publish their open source work. In this article, you will learn how to become as popular as them, and how to find potential contributors to enhance or debug your project.
Note: Part of this process might be facilitated in the future by Wakanda, but it is always good to learn the basics of Git & GitHub.
Becoming part of the GitHub family
If you don’t already have one, create your GitHub account for free:
Then download and install the latest Git version
1:
Create an SSH key and register it in your GitHub account using the following tutorial:
If you are on Mac OS, you can also download the dedicated GitHub client:
http://mac.github.com/
Creating your first repository
Create a repository on GitHub to host your public repository:
Include this .gitignore file in the folder of your Wakanda solution or Studio extension, so only relevant files will be included in your repositories.
Don’t forget to add a README file in your repository to describe what your application is all about. Github will even display your README nicely if you format it using
Markdown2 and add a .md or markdown extension to it. This file should include the version number required to use your application or extension.
Inside the terminal, go to the folder for the Wakanda solution or Studio extension.
Create a local Git repository for it on your computer using this simple command:
git init
You can now bind this repository to the remote one on GitHub:
git remote add origin git [at] github [dot] com:{GitHubUserName}/{repositoryName}.git
Add your existing files in this local repository and do a commit to save them as a current version:
git add .
git commit -m ‘first commit’
Such actions will allow you to subsequently save many versions of your work while you are developing it.
To publish your version on the public GitHub repository, use “push”:
git push -u origin master
You will now see it available in public on GitHub at this URL:
Congrats! You made it!
Having your work referenced
Go to
“wakanda-sampleapps” or
“wakanda-extensions” and create a “Fork”.
You will have your own version of “wakanda-sampleapps” or “wakanda-extensions”
(Ex: https://github.com/{GitHubUserName}/wakanda-extensions)
Now you’ll have to create a “submodule” in the fork
3.
Clone your fork of wakanda-sampleapps or wakanda-extensions on your computer and go to the matching local folder using the Terminal. Then create submodule:
git submodule add git://github.com/{GitHubUserName}/{repositoryName}.git {repositoryName}
It will create a folder {repositoryName} referencing your application or extension repository
Then go to this folder:
cd {repositoryName}
and reference the remote repository (the one on Github)
git remote add push git [at] github [dot] com:{GitHubUserName}/{repositoryName}.git
Initialize and load your project in the folder
git submodule init
git submodule update
Come back to the fork folder
cd ..
And synchronize the remote fork repository
git push
You should now see a folder referencing your application or extension repository in your fork on GitHub and a
.gitmodules file.
The last step is to ask the Wakanda team to reference your work via a “pull request.” They will just check that you’ve respected the basic guidelines and should then accept it. If not, you'll receive a message explaining what might be wrong. Feel free to ask if you have any doubt!
1 Git tutorial: http://excess.org/article/2008/07/ogre-git-tutorial/
2 Additional rich text features are supported: http://github.github.com/github-flavored-markdown/
3 GitHub submodule tutorial: http://help.github.com/submodules/
Add new comment