Jump to content

Question for developers - How do you store your code.


Ninjakreborn

Recommended Posts

I notice in this field we work with a lot of different things. A lot of developers also work with a lot of other languages. Obviously the goal is to write code once, and never have to write it again..in a way. WHen you figure out how to do something new, generally developers stick it into a function so they can re-use. I am starting to notice that over the years..I work with different frameworks..and sometimes without one. I noticed a long time ago that if I keep a customized copy of cake for example..or code ignitor..one day I might be working with something else. 

 

What I am asking is what do you do to keep your code together over multiple projects.  Javascript is another example. I have seen people who have taken a custom javascript class that they built..everytime they develop a new javascript function they load the function up into there universal class..then they include that javascript in any job their working on. Same with PHP, I have seen some develop classes for PHP and keep them all together. I am sure other languages: C++, Ruby, Python, and other languages you can do the same.  What do you do to keep track of code you have written.

 

My generally thoughts were to make a SVN setup on my server and use that basically to store a base copy of all of my stuff. If I think of a good javascript function, or group of functions I can load them into SVN so I can always get them if I wanted.

 

How do you store your code?  Or if you do a really cool implementation for a project...is there anything you do to replicate that functionality and put it somewhere so you can put it later on a project.

 

This includes classes. A lot of people find some classes they really like..how would you keep track of the ones you liked or use on future projects so you won't have to keep looking them up every time.

Link to comment
Share on other sites

I sort of have my own framework. I have a structure and stick to if for each project. I have a db class that I use in every single MySQL-related project. It dramatically speeds up my writing of select, insert and update queries. I have a message class which handles all error and success messages that are created for the user to see. That has also dramatically increased my productivity. The rest of my classes are all built to work with those two classes.

Link to comment
Share on other sites

I thought about that. I use to. Once I took a Codeignitor framework a long time ago and I was using it.  But after awhile (since I freelance) I had to jump around a lot. I used Cakephp, Zend Framework, Symphony and a score of other frameworks that were custom built..not to mention working with systems like Drupal, Joomla, Wordpress, and various forums.  All-in-all I barely got to use it, because when I was able to use Codeignitor for a new project, I always ended up using the original.

 

I also thought about putting all my code, snippets, functions classes inside my planner: www.essentialpim.com is what I use.  However it's kind of acward to get them from there.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.