C
C#9mo ago
The Hyper

Need help on git pushing a C# project

When I first uploaded my project on github, I've done it using the website's file adding. It seemed pretty dumb and tedious to select all the files one by one, so I wish to upload the whole project folder this time, thanks for your help. Existing project that I wish to update: https://github.com/TheHyper-Dev/Call-of-Duty-Movement-in-Godot-4
GitHub
GitHub - TheHyper-Dev/Call-of-Duty-Movement-in-Godot-4: A Godot 4 p...
A Godot 4 project that imitates the movement mechanics of Call of Duty games - TheHyper-Dev/Call-of-Duty-Movement-in-Godot-4
10 Replies
Jimmacle
Jimmacle9mo ago
what do you need help with? do you have a local git repo or is the only git involved the repo on github?
The Hyper
The HyperOP9mo ago
I have a project on my PC that I've newly worked a lot on, now I want to upload it and overwrite the existing github project
No description
Angius
Angius9mo ago
$gitstarted
MODiX
MODiX9mo ago
git init initializes the repository dotnet new gitignore adds a .gitignore file git add . starts tracking all files git commit -m "[message]" creates a commit git remote add origin [url] adds a remote repository git push -u origin main first push, sets the remote as upstream git push all pushes after that can be just this Git cheat sheet
The Hyper
The HyperOP9mo ago
ah great, thanks, one more thing I gotta have a godot 4 gitignore file don't know how to do that through code
# Godot 4+ specific ignores
.godot/

# Godot-specific ignores
.import/
export.cfg
export_presets.cfg

# Imported translations (automatically generated from CSV files)
*.translation

# Mono-specific ignores
.mono/
data_*/
mono_crash.*.json
# Godot 4+ specific ignores
.godot/

# Godot-specific ignores
.import/
export.cfg
export_presets.cfg

# Imported translations (automatically generated from CSV files)
*.translation

# Mono-specific ignores
.mono/
data_*/
mono_crash.*.json
this is the gitignore
Angius
Angius9mo ago
Yeah, seems fine
The Hyper
The HyperOP9mo ago
I got no idea how to make this on cmd.exe I assume this replaces the "dotnet new gitignore"
Angius
Angius9mo ago
There usually is only one gitignore, yes Why would you want to... dunno, create this specific gitignore via the command line? Just open the file and add the lines you need
The Hyper
The HyperOP9mo ago
cause there's a folder with tons of unnecessary files related to the Godot game engine
Jimmacle
Jimmacle9mo ago
via the command line
you don't need to make a .gitignore through code, it's just a text file also, since you already have a version on github those instructions from modix aren't going to work exactly right if you care about the version history on github you'll need to clone it, replace the contents with your current version, then make a new commit otherwise just follow modix instructions and add -f to the push to overwrite anything that's on github
Want results from more Discord servers?
Add your server