A sample .gitignore file for if you’re working with .net:
Also, if you happen to have added some files you didn’t mean to:
git rm –cached file_you_dont_want.pdb
git commit -m “Remove pdb file”
Thanks to these stackoverflow posts for the info:
Today I needed to import an existing project to Bitbucket. The documentation is really good, but just in case you have trouble finding it:
- Navigate to the root directory of your project.
- Run the following commands in terminal/command prompt:
git add –all
git commit -m “Initial Commit”
- Login to Bitbucket and create repository.
- Locate the clone URL (left menu) e.g. https://email_address.bitbucket.domain:7999/project_name/repo.git
- Upload your files:
git remote add origin https://email_address.bitbucket.domain:7999/project_name/repo.git
git push -u origin master
Check out the following link for more info: https://confluence.atlassian.com/bitbucketserver/importing-code-from-an-existing-project-776640909.html
I ran into the following error over the weekend while trying to push to heroku:
Running: rake assets:precompile
could not connect to server: Connection refused
Is the server running on host “127.0.0.1” and accepting
TCP/IP connections on port 5432?
This stackoverflow post helped to solve the issue. All you need to do is add the following line to your application.rb file:
config.assets.initialize_on_precompile = false
Let me know if you have any problems.
Just a quick post showing the config I needed to use in order to get KDiff3 working with git. It took a while to get this working so hopefully it’ll be able to help someone else out.
email = email@example.com
name = test
editor = \"C:\\Program Files\\Sublime Text 2\\sublime_text.exe\"
whitespace = fix
branch = auto
diff = auto
interactive = auto
status = auto
pager = less -FRSX
whitespace = cr-at-eol
autocrlf = input
excludesfile = /Users/test/.gitignore_global
editor = mate -w
co = checkout
lg = log --graph --pretty=oneline --abbrev-commit
recentrepo = Y:/Projects/Junk
recentrepo = C:/xampp/htdocs/onlinemedia
tool = kdiff3
Screenshot of git config from GUI:
Git Config KDiff