python-forum.org

This is the place to post any code that you want to share with the community. Only completed scripts should be posted here.Note: posts here are not necessarily endorsed by the community, and may represent amateur or even bad practices.

Thanks for trying to put your project on github. This is a good step. You seem to have done something wrong though. You placed all your code in the file .gitignore. This is incorrect. .gitignore is a file that only contains the type of files you don't want to end up in your repo when you commit/push.

It seems you accidentally named your repo the name of the script and for some reason put your code in the gitignore. Git is a bit tricky to use at first so feel free to ask if you get stuck. Assuming the original file is in the repository directory on the computer you work on, change the .gitignore to look like the above file. Then save your actual code as 'whatever.py'. Then add both of these changes with:

Mekire wrote:Assuming the original file is in the repository directory on the computer you work on, change the .gitignore to look like the above file. Then save your actual code as 'whatever.py'. Then add both of these changes with:

I don't know how you specifically are interacting with git. I have a program that lets me open a git terminal window (on windows 7). All git commands go in there. Git takes a little work and will require you to do some research until you are comfortable with it.

Much better. My criticism now is however, that your file doesn't have a proper file name. If you had named it kill_the_colony.py then github would automatically display it using a python syntax highlighter making it much easier to read. Also, as I said, since you have a repo, just include your graphics in the repository instead of using the image_from_url function.