Setting up mysql on Fedora

This is a quick how to on setting up mysql on Fedora. These commands are run on the terminal and may require root access. To change users use this command: su root
Install mysql packages:

yum install mysql mysql-devel mysql-server

Start the mysql server:

service mysqld start

If you want the mysql service to start everytime the machine starts do:

chkconfig mysqld on

Set up the root password for mysql:

mysqladmin -u root password <strong><em>yourpassword</em></strong>

To get into a mysql prompt do:

mysql -u root -p

The above will change your terminal prompt from something like “[annasob@ireland 1.0]$” to “mysql>”

Create a User and set their privileges in a mysql prompt

CREATE USER 'monty'@'localhost' IDENTIFIED BY 'some_pass';
GRANT ALL PRIVILEGES ON *.* TO 'monty'@'localhost' WITH GRANT OPTION;

After this you can create databases and create tables.

View all of my blogs

Building on Fedora 13

Prerequisites:

Run this command in terminal note that you need to do this as root. To switch to the root execute the command: su root

There is going to be some dialog so pay attention and answer y to everything

sudo yum groupinstall 'Development Tools' 'Development Libraries' 'GNOME Software Development'
sudo yum install mercurial autoconf213 glibc-static libstdc++-static yasm wireless-tools-devel mesa-libGL-devel

Building

1. Get the source code

hg clone http://hg.mozilla.org/mozilla-central/ src
cd src

2. Make a .mozconfig file and put it into the directory (src) you made above. The file should contain:

. $topsrcdir/browser/config/mozconfig
mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/objdir-ff-debug
mk_add_options MOZ_MAKE_FLAGS="-j2"
ac_add_options --enable-debug
ac_add_options --disable-optimize

Note these options are for a debug-build

3. Run the make file

make -f client.mk

4. Run firefox by going into the src/objdir-ff-debug/dist/bin directory and either double clicking on the icon or via the command ./firefox

 

View all of my blogs

View all of my blogs on Building

Popcorn-js 0.2v Release

If you haven’t heard about popcorn-js you are seriously missing out. Some Torontonians refer to it as CP24 online but of course its much better –  it’s open-source and allows anyone to make a content driven site. [Read my last post to get a better overview]  It has been less than 6 months since the initial launch of popcorn-js and only 1 month since our decision to make it into a plug-in architecture. Yes, we revamped the entire library in just one month.

Whats Changed?

In short everything; we re-wrote the entire thing. Using a plugin architecture enables people to easily add functionality to the library. Before, in order to get new features people would have to hack the actual popcorn.js file. Now they can make their own files (plugins, parsers) and simply use them. Another advantage of this is the fact that people will no longer need to write XML, although it is still supported.  Check-out the complete changelog. Read bocoup’s blog about the design.

Another exciting addition is butter. People who don’t want to code will need “butter for their popcorn”. Butter 0.1v has just been released. It is an online tool that enables anyone to make a popcorn.js enriched webpage. You just give it a link to your video, choose your plugins, fill in the needed data and it generates a webpage for you!

Looking to get involved?

There is countless ways for people to get involved in the project including idea generation, video generation, bug filing, documentation, promotion, and of course writing code. If you want to get involved here is a list of links to get you started:

View all of my blogs on popcorn-js
View all of my blogs

Seneca at polytechnicscanada.ca

Polytechnics Canada is a national alliance made up of nine institutions dedicated to helping colleges and industry create high-quality jobs for the future. The members include Seneca College, Humber College, Sheridan College, OLDS College, George Brown College, Conestoga College British Columbia Institute of Technology, Algonquin College, and SAIT Polytechnic. The idea here is to work closely with companies to promote innovation and practical applied research.  Being a graduate, and now working for Seneca College, I have the opportunity of working with industry partners. Seneca’s Centre for Development of Open Technology is currently working with Mozilla, NexJ, Aerius 3D and Fedora. Out of all the research projects at Seneca, popcornjs was chosen to be presented at the 2010 Polytechnics Canada meetup. Each member was to choose one project that would be presented by a student during a 5 min Power Point presentation. Yes Power Point. 5 min 5 slides. Not sure how that promotes innovation but I guess it allows for a controlled environment with flawless transition from one presentation to the next. Being part of the popcornjs team I volunteered to present. For those of you who do not know what popcornjs is you have to read my blogs more often. I joke. Popcorn.js is a JavaScript library aimed at allowing non-technical people to manipulate open video on the web. It provides a way for filmmakers to control the environment in which their video is viewed by integrating semantic content (wiki articles, google maps, google news, webpages, twitter, flickr) with HTML5 video. I created a demo specifically aimed at explaining what popcorn can do for this presentation. View it here.  Some of the other student presentations consisted of new concept wind mills, water oil filtration units, and high tech. lenses.

After the 5min presentation came the “elevator pitch” to the Minister of Stats for Science and Technology Gary Goodyear. We were suppose to pitch our projects. I was prepared, at least I thought I was.  I had it all figured out. I was going to start with “Imagine CP24 on the web” a simple statement that I thought would get his attention. After all I heard a lot of people refer to CP24 while explaining popcorn it really is a close comparison. However, during dinner, i was sitting beside a member of NSERC and as soon as he realized that I was to do a pitch he said “pitch me”. So I went for it and got blown out of the water. Whats CP24? he asked. He continued to state that he and the Minister would be interested in knowing how popcornjs impacts Canada’s economic growth.  Well? How doest it? I mumbled something about revolutionizing the web and bringing Canadian developers to the top of Internet technology. But really popcornjs in an Open Source project that will not make or save a particular company millions of dollars. However, it has the potential of blowing up. I mean popcornjs was already featured in Wired’s webmonkey, and CHIP an online magazine. But how does one put a price tag on something that is free to use? Anyone?  Please comment if you have any ideas as I am sure this question will appear again.

 

View all of my blogs on popcorn-js
View all of my blogs

Popcorn-js Gets a Face-lift

Since May 2010 I have been involved in a Mozilla sponsored project popcornjs. The project aims at bringing filmmakers and artist to the web by providing an easy way to add extra data to their videos. So instead of posting their video on youtube or vimeo – websites that decide what the viewer sees around the video. They can host their own video and use popcorn to display timed data such as wikipedia articles, google news, google maps, flickr, twitter, and websites. Of course the time at which this data comes in and out can be controlled.

Because the initial aim of this project was to make it easy for non tech savvy people to use, we used an XML structure to control what data would be used at what time during the video.  As the project received more exposure, we were getting more and more feedback. This feedback included requests for more feature supports such as Open Maps, and a more flexible Twitter function. As well as a better way of allowing users to add their own functionality. As it was, users had to dig in to popcorn’s core in order to add anything new. Our choice of using XML has also been questioned.

To combat all of this and also to bring popcornjs to the next level Mozilla decided to bring in the big guns. Bocoup is a Boston based company that has a lot of experience with jQuery and its plug-in architecture. They have taken popcorn under their wings and recommended a plug-in architecture that both developers and filmmakers will be happy to use. This is not to say that they have taken over the project. Their main goal is to build butter. A popcorn UI that anyone can use to produce a popcorn enhanced website. User will fill out what feature they want and the in and outs and then press export to generate a webpage with a default template. Most of the code updates will still be done by Scott and I. However, Rick, Boaz, and Al will guide us along the way.

So the bottom line. Popcorn now fully supports plug-ins. We are still working to convert all of the functionality into plug-ins but when we are done anyone will be able to write plug-ins. This will include parsing different types of data (JSON, QuickTime export format)  and DOCUMENTATION.

Read more about this: Scott’s blog, bocoup’s blog.

View all of my blogs on popcorn-js
View all of my blogs

Seneca at technicity.ca

On Nov 30, 2010 Seneca was invited to showcase their IT work at technicity.ca. The Technicity event’s goals were to acknowledge the talent we have in Toronto and bring forth a plan of action to foster this talent. David Crow talked about how people tend to go to California or Boston to look for talent even though Toronto has some of the best schools.  Seneca was fortunate enough to get invited to the event. I along with Scott Downe and Andor Salga got a change to showcase our work including processing-js, popcorn-js, pointstream, and c3dl. I must say that the crowd was amazing. We got a lot of positive feedback including “this is a jewl… don’t give it away, sell it” — about popcorn. Usually we are faced with people that do not have a good understanding of technology and it’s capabilities. However at technicity we were faced with people that did not understand why or maybe how people can make money doing open-source development.

 

View all of my blogs

Yet another way Git make the review process better

As you may know from some of my posts, I am a frequent user of GitHub.  When I started using it I didn’t realize how powerful it was. However, as time goes on, Git is looking to be more and more of a manager’s tool. When I first volunteered to help manage the processing-js project I wrote a set of guidelines that incorporated the use of Lighthouse and GitHub. The basic principle was “tell people what you are working on and the status” on Lighthouse, “do your work and let others look at it” on GitHub and finally “ask people to review” on Lighthouse.  It now seems that GitHub has the ability to do all of the aforementioned items.

Pull Requests

Once you have finished a patch you can request that the owner of the repository who’s code you have forked reviews it. This is done by selecting the pull request button which opens up a discussion between you and the person who owns the repository you have a fix for. Like I mentioned this is a discussion, you and the other person can go back and forth several times before he/she is ready to pull (accept and add to their repo) your code. Git will tell you when a new note was added to the discussion or when any other actions were taken. A pull request is a fast and easy way to see all of the commits associated with the pull request without having to leave the page.

Commit Notes

Once you have committed anything to git you will get a commit url (example). This is a summary of all of the files that were changed including their specific line numbers as well as the before and after identified with a (-) and a (+) sign. This lets the person looking at your patch know exactly what you added/replaced/deleted. When a person looks at the commit with the intention of reviewing it, he/she can add comments to any line that you have edited. This is done by clicking on the line number of the file you would like to add your note to. Here is a sample commit with notes.

I think you probably know where i am going with this. If a person has a patch there is no need for them to go on lighthouse and comment on a ticket. Further, there is no need for the reviewer to comment on their patch on lighthouse. All that is needed here is Git. Git gives you the ability to ask for review, get comments on a review, fix any issues, request another review, and have your code accepted all under one discussion. I know what you are thinking, how does one replace the bug tracker in order to ensure no two people are fixing the same bug. Which brings me to another one of GitHub features, git pages.

GitHub Pages

GitHub allows you to add a custom page to your repository. This page can be whatever you want it to be. You can use it to list the functionality you have yet to implement or you can simply point it to a wiki where that list can be found. Here is a short guide on github pages.

View all of my blogs on GitHub
View all of my blogs