How to upload project to github
How to upload project to github
How to Upload a Project on Github?
A lot of students ask questions about open source. What is open source, how can I contribute to it? Is it helpful if I contribute to open source, and the list goes on relevant to “Open Source”.
So what is open source.
According to opensource.com, The term “open-source” refers to something people can modify and share because its design is publicly accessible.
The term originated in the context of software development to designate a specific approach to creating computer programs. Today, however, “open-source” designates a broader set of values — what we call “the open source way.” Open source projects, products, or initiatives embrace and celebrate principles of open exchange, collaborative participation, rapid prototyping, transparency, meritocracy, and community-oriented development. i.e., “open-source is what is free to access by all. Anyone can change and distribute its own model”.
There are so many blogs available on the internet to learn about open source, software, and their importance. The most common and widely used platform to use for open source is Git and GitHub.
The purpose of Git is to manage a project, or a set of files, as they change over time. Git stores this information in a data structure called a repository. A git repository contains, among other things, the following: A set of commit objects.
GitHub is a Git repository hosting service, but it adds many of its own features. While Git is a command-line tool, GitHub provides a Web-based graphical interface. It also provides access control and several collaboration features, such as wikis and basic task management tools for every project.
Let’s discuss some command used in git to push, pull, commit and do changes to your GitHub repository.
Great You have successfully uploaded your files to your GitHub repository.
All the files and directories are uploaded to your Github account. Now you can manage, revert, access or do any changes in your repositories like this.
Upload Project/Files On Github Using Command line
Upload file to github command line. Today we will learn how to easily upload project or file on github using command line. First we will create a new repository on github and after we will fill the repository name and description.
Upload Project/Files On Github Using Command line
Follow the few steps and successfully upload file or project on github using command line.
Step 1 – Create New Repository
Create new repository On Github
Fill the repository name and description of your project.
Step 2 – Now Open cmd
Now go to the Terminal on your computer system. Use cd to navigate to the local project directory that you want to publish on GitHub.
CD to navigate to your directory
Step 3 – Initialize Local Directory
Now we will intialize our project. Use the below command to initialise the local directory as Git repository.
Step 4 – Add Local repository
Add all the files in the local directory to staging using the command below.
This command stages all the files in the directory, ready for commit.
Step 5 – Commit Repository
You can now commit the staged files using the command below. It is explanatory and helpful.
Step 6 – Add Remote Repository url
Now, copy the remote repository URL provided by github to you when you published your repository on GitHub.
Now we will add the copied URL for your GitHub repository as remote repository using the code below.
This command add our GitHub repository as a remote that you can then push your local repository changes.
Step 7 – Push Local Repository to github
In the last step, use the below command line in your terminal to push the local repository to GitHub. It will upload the file or project on github.
Step 8 – Pull Repository from github
Pull the desired branch from the upstream repository. This method will retain the commit history without modification.
All the command to use upload the file and projects on github.
In just few minutes. We have successfully upload the project or file on github using command line
How to Upload Project on GitHub from Pycharm?
PyCharm is one of the most popular Python-IDE developed by JetBrains used for performing scripting in Python language. PyCharm provides some very useful features like Code completion and inspection, Debugging process, support for various programming frameworks such as Flask and Django, Package Management, etc. PyCharm provides various tools for productive development in Python.
Git is an open-source version control system. It means that whenever a developer develops some project (like an app) or something, he/she constantly update it catering to the demands of users, technology, and whatsoever it maybe. Version control systems keep these revisions straight, storing the modifications in a central repository. It allows developers to easily collaborate, as they can download a new version of the software, make changes, and upload the newest revision. Every developer can see these new changes, download them, and contribute. Git is used to storing the source code for a project and track the complete history of all changes to that code, while GitHub is a cloud-based platform built around the Git tool. So it’s necessary to upload your project on GitHub.
Prerequisite: Before going through this article consider that one must have already a GitHub account. Also, consider that one must have already a developed Python project on the Pycharm.
Step by step process to upload the Python project on GitHub from the pycharm:
After clicking the Enable Version Control Integration a pop up will arise like following. Then select Git from the drop-down menu and click OK. This will initialize the project for GitHub.
After clicking this a new screen will pop up like the following. Now, first, select the unversioned files, then input the Commit message as “Initial Commit” and then click on the Commit button.
After clicking this a pop up will arise where the user has to enter its GitHub login id and password. After successfully logged in to its account one more pop up will come like following where the user has to give its Repository name and the Description of their repository. Then click on the share button and done.
Note: Don’t put blank spaces or special characters while giving the Repository name.
How can I upload my project’s Git repository to GitHub?
I have installed the Git EXE file for Windows at my machine. I have also created my account at GitHub. My requirement is simple—how do I upload my project, say one folder and two files in it, to GitHub?
2 Answers 2
Trending sort
Trending sort is based off of the default sorting method — by highest score — but it boosts votes that have happened recently, helping to surface more up-to-date answers.
It falls back to sorting by highest score if no posts are trending.
Switch to Trending sort
First follow these steps to create an SSH key: http://help.github.com/win-set-up-git/
Then create a local repository on your computer and push it to GitHub with these instructions: http://help.github.com/create-a-repo/
Go to GitHub, on the top right press the «+» button, and choose New repository. Give it a name and adjust the settings you want and press *Create repository. After doing so, you should be redirected to a page containing some commands, which means you have been doing everything right until now.
Open your Git repository and go to the folder you want. For example, if the folder’s name is «Demo», use the command «cd Demo». After that, type
to create a new Git repository. Then use
This adds the chosen file to the staging area, telling Git to keep track of that file. After doing so, make a commit by simply writing
Uploading your project to GitHub
You’re an upload away from using a full suite of development tools and premier third-party apps on GitHub. This course helps you seamlessly upload your code to GitHub and introduces you to exciting next steps to elevate your project.
From private betas to the most important open source technologies of our time, GitHub is home to all kinds of projects. Developers count on our platform to take their projects to the next level with collaborative tools, uncompromised security, and premier third-party apps.
If you haven’t started your project on GitHub, uploading your project might feel overwhelming. This course helps you seamlessly upload your local project to GitHub and provides important next steps for managing your project and introducing community involvement.
What you’ll learn
In this course, you’ll learn how to:
You’ll know the answers to questions like:
What you’ll build
At the end of this course, your project will be on GitHub and ready for version control, and have all the collaboration features of GitHub immediately available. You’ll have access to issues, pull requests, project boards, wikis and management features.
Prerequisites
In this course, we assume you understand what a repository is and how to work with files and folders locally. We also assume you have experience using either the command line or can download software to help move files to GitHub. If you need some help with learning GitHub terminology, try taking Introduction to GitHub first.
Projects used
This course is open-ended, and you can choose which tooling you’d like to use. Some of the options include:
Who this course is for
This is a great follow up course from Introduction to GitHub. If you have a project you’ve been working on and want version control and collaboration features, this is the best course for you.
Plan the upload
Explore your options for making the move to GitHub.
Источники информации:
- http://www.tutsmake.com/upload-project-files-on-github-using-command-line/
- http://www.geeksforgeeks.org/how-to-upload-project-on-github-from-pycharm/
- http://stackoverflow.com/questions/6674752/how-can-i-upload-my-projects-git-repository-to-github
- http://lab.github.com/githubtraining/uploading-your-project-to-github