So, we are going to discuss in detail how to host any file using Google Code and Sub Version Client. After reading this tutorial you will know about
- Project Hosting using Google Code;
- Working with SubVersion using Free Clients like TortoiseSVN; Uploading and Downloading files using it;
- Working with mime-type.
- Obviously, successfully hot linking files directly from Google Codes;
So read on to know how…
#1: Registering to Google Codes and Creating a New Project:
If you have not already, then, go to http://code.google.com and register with your Google Account. Now follow these steps:
- Go to the Project Hosting page and click on the Create a new project; This will take you to a page to create a project from where you will be hosting your static files.
- Now fill in the details as shown in the figure. Make sure that you have selected “Subversion” as Version Control system. Click on the Create Project button when everything is done.
- Once the project is created, the main Project page will be shown to you. Navigate to the “Source” tab from the project page.
- Here you will find something like this …
- Note down the URL of the svn checkout and then click on the googlecode.com password. Note down the password. We will need the URL and the password in the upcoming steps. These will be used to login to the repository where from we will be serving the static files. So do not share the password with any one, else other might be able to edit/remove/modify your files!
Now you are done creating the project and collecting necessary information. Our next step will be to download and configure Subversion clients.
#2: Downloading & Configuring TortoiseSVN
As said before, we are going to use TortoiseSVN as our Subversion client to upload our static files with proper mime-type. Here are the download links…
- Home Page: Click Here;
- Download Page: Click here and download either 32 or 64 bit version according to your operating system [Mostly 32 bit]
Note that tortoiseSVN is a shell control client. Which means, you do not actually need to open up a new software. Just Right click where ever you are working on Windows Explorer and you are ready to launch TortoiseSVN. Now just do the following tweaking…
- Right click on any open Windows or desktop and navigate to Tortoise SVN > Settings. This will pop up the settings page.
- Now click on the “Edit” button. This will open up a notepad with a text document.
- This document holds all the records for the mime-type of the files to be uploaded. We need to add a list of mime-type according to extension on this file.
- Just after the end of the text document, press enter and copy paste all the texts from the box below.
- Save the text document and you are done. Now press OK on all the open SVN windows.
Note that you need to append the texts after the existing texts on that document. If you face any problem then do ask through your comments. This step is necessary to host the files properly!
Now that you are done tweaking, lets see how we can actually upload files using the client.
#3: Uploading files using Tortoise SVN client:
- Open the folder where from you want to upload the files. Now Right Click and navigate to TortoiseSVN > Repo Browser. Enter the https URL you have noted from the step #1.
- A dialogue box will prompt for your username & Password. Enter the your Google account Username and the googlecode.com password you have noted.
- Now the repository browser will open. Make folders according to your need [Just Right Click and Create a Folder] and drag and drop the file you want to upload and click Copy Items Here.
- Wait till SVN client uploads the files.
You are done uploading. If you have configured TSVN properly then it will upload with proper mime-type and the file is ready for hot linking. Do the following for getting the URL:
- Left click on the file you want to hot link from the repository browser and select and copy the URL. Just replace the https with http and you are done.
Now you have got the URL to hot link. Use it where ever you like.
So, that was a detail discussion on how to hot link files using Google Codes. Using this method, you can easily host your CSS and JS files for your Blogger Blog. I hope you have liked this method. Do give us your feedback on this article. Also if you face any problem or confused about any step feel free to ask through your comments.
Logo Image Credit: Thomas Hawk
Thanks .. it worked like a miracle.
followed the steps – this was a great hlp
I hosted with github and linked the css file in my html website but it doesn’t work. Please help. (Used raw link )
thx, good post
PD: sorry my poor english, but css file no conect o syncronize with google code with my blog (google blogger), why that suced, thx in advance!
Thank you very much for writing this. I was trying to host my code on google drive and dropbox, then link to it that way. i did not realize there was more to it than that.
I want to use it as my web server in facebook. But there’s a problem that the facebook request my page in a form post. Like this:
And the google server responds with the following message:
Method Not Allowed
The requested method POST is not allowed for the URL /svn/index.html
The concept is to use static files not something which will POST data.
thank’s it’s really help me 😀
Comments are closed.