Mentoring for Google Code-in – WikiToLearn

Google Code-in

Google Code-in has just begun. I’ll be mentoring this time. πŸ™‚

If you know any pre-university students who are interested in computers or open source please do inform them about this. Task varies from coding, documentation, training, outreach, research, quality assurance and user interface. Also, students earn prizes for their successful completion of tasks.

What is Google Code-in ?

Google Code-in is a contest by Google to introduce pre-university students (ages 13-17) to open source software development. Since 2010, over 3200 students from 99 countries have completed work in the contest.

What I’ll be doing ?

I’ll be mentoring for tasks under WikiToLearn, KDE organization.
I have published a task related to WikiToLearn community : What can I do for WikiToLearn

I’ll be helping students with code and design for this task.

I have few other tasks in my mind. I may publish them as we move on (based on our progress).

Why I’m doing this ?

Well, I just love open source and like helping others to get into FOSS. And WikiToLearn, KDE is a great community to work with.
I strongly believe in it’s philosophy – “Knowledge only grows if shared”. It feels good to help the younger generation to get into community so that our community grows big.

Join WikiToLearn now and contribute however you can. πŸ™‚

Advertisements

SwiftCode at BNMIT

Firstly, check out our technology stack :

swift-code4
It is Play framework, REST API, Java, AngularJS, MySQL, we deploy our application on AWS, Heroku. All our development happens over Lubuntu, a lightweight and fast operating system. We make use of Git along with GitHub for version control.

What is SwiftCode ?

SwiftCode program is intended to show a modern age computer science graduate how to build scalable and robust applications using state of the art techniques and design methodologies that have shaped software today.

This blog post beautifully explains how we set up collaborative development environment for our workshop : How to Quickly Set Up Collaborative Software Development Environments

On August 20th, we hosted our first workshop at BNMIT engineering college, Bangalore. We had 25 students from Computer/Information Science department.

On the first and second day, Sandeep and Akshay took the session on Java Play framework, explaining how to build a RESTful application. They completed the backend side of the application. Students were often made to commit and push their code on Github. At the end of day 2, Shrita showed how to test our APIs using the Postman.

On the third day, Prarthana took a session on front-end development, talking about how responsive websites could be built using bootstrap, architecture of Model-View-Controller (MVC) and AngularJS.

At the end of the training, all students were able to build a social media (similar to facebook) application on their own. They had soo much fun and learned a lot.

You can see all the repositories created by them at our GitHub org : https://github.com/swift-code

This slideshow requires JavaScript.

Image source : SwiftCode

It’s a great start to our long journey. Keep waiting to know about our next stop! πŸ™‚

[To be continued…]

One last step for completion of Google Summer of Code – KDE – WikiToLearn

One last step for completion of Google Summer of Code – KDE – WikiToLearn

Collaborative Editor Extension for MediaWiki
The Google Summer of Code 2016 is coming to an end, just couple of days left.

The good thing is that I’m also almost done with my project and enjoying my free time. πŸ™‚

I have published the screencast of how my project (Collaborative editor extension) works on my laptop.

YouTube : https://youtu.be/lf1Kg0gVIWk

I had built the extension on normal MediaWiki.
I tested it on my local instance of WikiToLearn i.e http://tuttorotto.biz (URL is accessible only if you are running its local instance)
It works good and as smooth as it was on MediaWiki.

The things I’ve planned to work on these final days are :

* Write good documentation. Since my project was bit complicated, I do feel it requires a good documentation on how does it work, how to use it and configuring it.

* It may need some tweaking on UI so as to match with the current skin of WikiToLearn. It would be easy, we can do it anytime but my focus is on get the collaborative editing work good.

* I’m curious to know how it would perform when we deploy it on staging or production server. I know WikiToLearn will be used by the huge number of people every day and hence it will have high traffic.

I’m also looking for any good tool to write my documentation. Maybe GitHub wiki, ReadTheDocs or a blog post would be fine I think.

Hope all these goes well. πŸ™‚

Cheers!

[Edit]
Testing Rich Elements.

YouTube : https://youtu.be/T3KyDwNi_VM

Weekend.py

On 23rd and 24th of April, 2016 our GLUG DSCE organised a basic Python and Django hands-on workshop.
python
On 23rd, Santosh from HackerEarth taught the students about basic python programming. The duration of this workshop was around 3 hours. Most of the basics concepts were covered. Most of the students who attend this workshop were from 4th-semester. They knew about C programming and Object oriented programming language like C++ which helped them to learn python quickly.

They all were amazed at the flexibility providedΒ  by the python. Santhosh’s talk was impressive enough for students to fall in love with python. πŸ™‚
T-shirts were awarded to students who solved the bounty questions quickly.

django

On 24th, we had Ramaseshan from Fractalio Data Pvt Ltd who took a hands-on workshop on Django. Firstly, he explained about the MVC, MTV architecture to make them understand how architecture plays an important role in building an application.

The duration of this workshop was around 5 hours (excluding 1-hour lunch break). We worked on a building a basic Django app – writing notes something like Evernote. It was taught very well.

At last, we had an hour for open discussion. Students were made to as any question related to Django or anything related to technology. I and Farhaan spoke about our GSoC project ideas and motivated them to contribute to Free and Open source software projects.

Ramaseshan spoke about Free Software philosophy, mesh network, censorship, privacy, free software communities and lot other things. His talk was very much impressive, many students wanted to join GLUG as core members and contribute in whichever field they are interested in. πŸ™‚

A meeting was conducted soon after the workshop with the newly joined GLUG members.

DuckDuckHack – Global Quack and Hack 2

 

duckduckhack-quack-and-hack-2

On 30th January, 2016 we had our 2nd global Quack and Hack meet-up. This meet-up was special to me because I got an opportunity to be a co-host. I should thank Abdul, DuckDuckGo community leader for giving me this opportunity.
It is great pleasure to be a host for this meet-up.

Daniel, the community manager of DuckDuckGo joined us over a video conference. He gave us some insights about the Global Quack and Hack meet-up which is happening at different parts of the world.

daniel
That’s Daniel on big screen.

After speaking with Daniel, I asked all participants to join our slack group.

I showed them the various features of DuckDuckGo search engine – instant answers, bangs, changing the UI theme, etc. I spoke about various ways to contribute to the DuckDuckGo’s open source platforms.

I gave a demonstration on how to build instant answers.

I tried to make them understand the code base of zeroclickinfo-goodies repository.
We were concentrating more on cheat sheets since it is good to start with for beginners, easy and can be finished in quick time.

Then we followed the documentation to set up the development environment. They didn’t faced any difficulties in doing this. Most of them were on Linux based OS.

Few of the participants were new to open source. They created an account on Github, forked the zeroclickinfo-goodies repository and cloned it.

Just to build confidence within themselves I made them to run the duckpan server on codio and test the existing instant answers on the local server. They were happy to see those search queries giving instant results.

This slideshow requires JavaScript.

Few of them selected ideas from the Instant Answers Ideas forum, few came up with their own ideas.
They started to hack on their ideas. I used to keep helping them whenever they find difficulties. Hemanth, another co-host joined the meet-up.

We took a break for lunch, had some yummy pizzas, sodas, chat with others, all these were fun. πŸ˜‰

This slideshow requires JavaScript.


By this time few of them were almost done with building their instant answers, they just needed to send the pull request.

All were new to git too. I and Hemanth, helped participants to configure git in their systems and thought them few basics of it.

Few were successful in sending the pull requests. It was really nice to see people making their first contribution to open source by building instant answers.

Thanks to Galaxy and Mozilla Bangalore community for providing their community space to host this event.

This slideshow requires JavaScript.


Happy to help more and more people to contribute to open source and DuckDuckGo anytime in future. πŸ™‚

Mistakes :

– We couldn’t watch these video collection. 😦
The blog post was published just few hours before the event. I’m missed to read this post, read after the event. My bad. 😦

– We started our event at 12.30 p.m IST, I felt if we had started by morning we could have stretched the duration till evening.

Issues faced :

– Few couldn’t send the pull requests though they had completed building instant answers. This is because more time was spent in configure git on their systems and explaining how git works. So, at the end we didn’t had enough time to complete it, we had to wind up.

What we can do for next event ?

– We could automate the process of sending invite link to subscriber to slack group. Similar to this.

– Need to do some more promotion of the event so that we can more crowd.

Totally, this meet-up was great fun and taught me new things. πŸ™‚

You can read about my post on 1st Global Quack and Hack meet-up here.

See you at next meet-up, until then happy quacking! πŸ˜€

#Quack #Quack

Git workflow

In my previous blog post, I wrote about why to use git ?

Now, let’s start working with it.

Since most of them prefer Github (proprietary) rather than Gitlab (Free). This will be in context with Github. There will not be much difference if you are using Gitlab, the workflow remains same.

I assume that you have created an account on Github and downloaded git in your system and configured it.
If not, follow this set up guide.

1. Fork the repository

First you need to fork the repository to your remote server. You can fork the repository by clicking on fork button (Ο’) which you see in the top right corner. Forking a repository is nothing but you have a copy of that repository on your account.

2. Clone the forked repository

If you want to make some changes to the forked repository, you need to clone it.
You can clone the repository by following command :

$ git clone {URL_of_the_repository}

In my case it will be :

$ git clone https://github.com/sagarhani/learn-git

In your case it will be :

$ git clone https://github.com/{your_username}/learn-git

3. Create a new branch

Now move inside the cloned directory by :

$ cd learn-git

It is always good practice to keep the master branch clean. So, create a new branch and work on that branch.
First, check currently which branch are you on, by doing :

$ git branch

It will show master.

You can create a new branch by doing :

$ git checkout -b my-feature

It automatically switch the current branch (master) to my-feature branch.

You can again verify it by doing :

$ git branch

This time it will show my-feature.

You can create any number of branches. You can switch to any branch at any point of time by :

$ git checkout {branch_name}

To switch to master branch :

$ git checkout master

4. Work on the feature

Now you can open your favourite text editor and work on the code. You can modify/add/delete files.

For example : Create a file hello.txt and add some text inside it.

5. Adding your work to staging area

Once you are done with working with code. You need to add them to staging area from your working directory.

Do :

$ git status

This will show all files which were modified and added or removed.

Now, you need to add these changes to staging area to tell git that you need to update these changes in you next commit.

You can add a file by :

$ git add {filename}

In this case it will be :

$ git add hello.txt

6. Commit your work

Git commit command commits the staged works snapshot to the project history. Committed snapshots can be thought of as β€œsafe” versions of a project. Git will never change these work unless you explicitly ask it to change it.

$ git commit

Commit the staged snapshot. This will launch a text editor prompting you for a commit message. After you’ve entered a message, save the file and close the editor to create the actual commit.

$ git commit -m "{message}"

Commit the staged snapshot, but instead of launching a text editor, use <message> as the commit message.

Commit a snapshot of all changes in the working directory. This only includes modifications to tracked files (those that have been added with git add at some point in their history).

$ git commit -a

Combining all the above you can simply do :

$ git commit -am "Added hello.txt file"

7. Update your remote repo with master branch of the original repo.

While you’re working, many other developers around the world have been busy merging changes to the original repository. Most likely there won’t be overlap, but there may be some merge conflicts if two people have made changes to the same Instant Answer.

It’s best practice to start each work session by updating your fork with the latest changes. This is one major reason we kept master free of changes. We can use it as an ongoing reflection of the original repository’s master branch.

To do this, you’ll need to add a ‘remote‘ that points to the original, main repository. We’ll call it upstream.

In this case the command will be :

$ git remote add upstream https://github.com/sagarhani/learn-git

Update your master branch. Move to master branch to by git checkout master

Pull the updates form the upstream

$ git pull upstream master

This will pull the changes from the latest master branch into yours, so you’re up-to-date.

Next, to update your working branches off of master, merge or rebase with the master branch.

If you encounter any merge conflicts, don’t worry, GitHub has a great guide for how to resolve them. πŸ˜€

8. Make a pull request

If you want to submit your changes, you need to make a pull request on the original (upstream) repository.

A pull request is the process of submitting changes to a collaborative project. It’s your way of asking that the changes made on your fork be incorporated into the original repository.

The first step to making a pull request is updating the clone of your repository that lives up on GitHub.com. Go to the branch you’re working on, and type:

$ git push origin my-feature

This updates the equivalent branch on GitHub.com. Next, visit your repository on github – https://github.com/{your_username}/learn-git. Find the branch you just pushed. Finally, click the Pull Request button.

9. Update your pull request

Once you have created a pull request, you pull request page will be the place where the feedback/discussion takes place. Usually the repo owner comments on the page if any changes is required.Β  You can continue to make ongoing changes to your pull request. Simply keep making commits – and push them your fork on Github – and the pull request will update automatically. Once it is satisfied by the repo owner he/she will merge it. πŸ™‚

Bingo! You made some contribution to that project. πŸ˜€