GithubHelp home page GithubHelp logo

Comments (12)

Sembrani avatar Sembrani commented on July 24, 2024 1

@dodekeract The .png should be set as binary so that git does not modify them, even through CRLF conversion. Looking at the current .gitattributes file, there is no *.png binary line? Perhaps this should be added.

*Edit: @dodekeract just re-read your comment, I believe you are correct, in that *.png binary should not have been removed. My apologies.

from dota2-thecore-config-engine.

FlorianWendelborn avatar FlorianWendelborn commented on July 24, 2024

You can actually make a pull request without breaking them. Just use the Git shell (or bash) and enter the following commands:

git clone https://github.com/username/repository
cd repository
make your changes
git add filename-you-changed
git commit -m "commit message"
git push

Then create the pull-request from your fork.

from dota2-thecore-config-engine.

Aevyz avatar Aevyz commented on July 24, 2024

The problem is my fork is all messed up, mostly my fault. Played around a bit too much. For some reason the Keyboard Images always are broken, like cannot open corrupted broken. Can't explain that, but whenever I pushed an update to my own fork, they wouldn't work. Also I'm using the Github app and not the shell (kinda too lazy to learn that right now).

from dota2-thecore-config-engine.

FlorianWendelborn avatar FlorianWendelborn commented on July 24, 2024

If your fork is all messed up anyway, just delete it and re-fork.

from dota2-thecore-config-engine.

Aevyz avatar Aevyz commented on July 24, 2024

Been there, done that. Computer still corrupts the PNG files for no apparent reason. I am planning to reinstall windows anyways during my summer break, so I'm gonna live with that problem until then.

Anyhow, I'm going to try it regardless, who knows, might work. Just thought I could post this here in the event that I can't fix it myself. Its better than leaving the bug in the wild without a fix.

Edit: Instantly have 9 corrupted images once I download the file. Guess I will try online editing...
Edit 2: As much as I dislike the online editor, I did it online

from dota2-thecore-config-engine.

FlorianWendelborn avatar FlorianWendelborn commented on July 24, 2024

You can chose which files to add to a commit, even in the GUI. Just untick them next time.

from dota2-thecore-config-engine.

Aevyz avatar Aevyz commented on July 24, 2024

Seems to work, thanks for the help. Now just to fix the PNG's, its messing with my OCD...

from dota2-thecore-config-engine.

FlorianWendelborn avatar FlorianWendelborn commented on July 24, 2024

@AetherV Does this look similar to your issue? http://stackoverflow.com/questions/19411981/images-corrupt-after-git-push

If yes, then I guess it's the recent CRLF change someone@Sembrani pushed to this repo. I think it's working fine for me since I'm on Unix but you're on Windows.

from dota2-thecore-config-engine.

FlorianWendelborn avatar FlorianWendelborn commented on July 24, 2024

@Sembrani I think you should revert removing that .png binary thing from .gitattributes, I assume this is causing problems here.

from dota2-thecore-config-engine.

Aevyz avatar Aevyz commented on July 24, 2024

Ehm @dodekeract, what does that exactly mean. I've tried reading through that 15 times and its still blowing way over my head. I copied and pasted the .gitattributes text and it seems to work. Don't know why, don't know how, just that it seems to somehow work again. Guess I got some reading to do about the gitattributes file.

@Sembrani, I am free to do some testing if you can give me instructions.

from dota2-thecore-config-engine.

FlorianWendelborn avatar FlorianWendelborn commented on July 24, 2024

@AetherV as far as I understand, Git thinks your .png files should be treated like text, aka - when you push the file, all 0x0A (Line feed) bytes get converted to 0x0D (Carriage return) + 0x0A (Line feed). This was setup because Windows is weird and needs CRLF to mark line endings, while most other OS just use Line Feed.

Converting either from CRLF to LF or from LF to CRLF (which this repository does afaik) will break binary files because 0x0A and 0x0D + 0x0A are no special characters in binary files, they are only meaningful in text files, which means the resulting files are complete nonsense.

If you're wondering why these bytes have these weird names, carriage return is related to typewriters, which actually had to return the paper to the start so they could write in the beginning of the line. 😆 Line feed means that the paper should shift a line down. Quite absurd if you think about it that we still use these terms and that Windows still "works like it would have to move the paper back to the beginning".

from dota2-thecore-config-engine.

Aevyz avatar Aevyz commented on July 24, 2024

Good to know. Never heard of that problem, but it seems to kinda make sense to me. Thanks for the explanation 👍

from dota2-thecore-config-engine.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.