gist
gist copied to clipboard
File language not saved back to github after editing in ST2
I open a Textile formatted gist, modify it, then save it.
When I look at the gist back on github, everything's fine beside for its language now set to Text instead of Textile. Is there any way to preserve the formatting?
I should mention it opens as a Textile file within ST2 just fine. It's just the saving that seems to go wrong.
Thanks!
I noticed this issue just now. Up until now I've been saving plaintext Gists, but I wanted to change it to Markdown for one so I changed it on the website, then made and edit and updated it, only to find it had reverted the Gist back to Plaintext :( I can imagine it isn't a hard fix to implement?
I can't replicate this. Can you link a gist with which this happens?
@deiga For me it happens with every gist.. Here's a screencast showing my issue: http://www.screencast.com/users/brandonb927/folders/Snagit/media/eca22434-27d7-45f0-b68d-ebfbc8991ef7
Okay, thank you for that. Was able to reproduce the steps.
You can avoid that by naming the file with the correct type in sublime. But I will investigate this now :)
After some investigation it seems that the problem is in the Gist API. Files just aren't renamed over the API.
Thats a shame :( Thanks for looking into it!
@brandonb927 Can you try again? I can't reproduce it now, maybe GitHud fixed this issue with API?
~~:+1: I seem to be having the same issue with a CoffeeScript file.~~ Disregard user error.
Hmm seems to be working fine again. Thanks for checking in on this! (sorry for the late response btw)
Great!
I am seeing this same problem on a private gist. It's a block of HTML and I can't change it from Text to HTML. It seems to work, but after saving it's back to text.
Ok, I think this is because it's preferring the filename to the user's selection. If I set the filename to end in html, it works. Should probably trust the user...
The bug still exists in private gists.
I just added the ".md" to the end of the file name when I uploaded (the original in sublime doesn't even need to be saved as such) and it uploads fine, even in private gists.
Can't change language in my public gist: https://gist.github.com/andrejsc/b2db1b18433e5cc1543a It was saved as HTML (but switched back to text), and now it won't update either.
Was having same issue with javascript, just added the js extension and it worked. Try renaming it bootstrap_center_div.html.
@yoaquim: thanks, changing title from Bootstrap center div to bootstrap-center-div.html helped. Now html is properly highlighted.
I ran into this today, IIS web.config
is actually XML, but it wont let me change it in gist.
https://gist.github.com/blowsie/04c183c62a432f6450c9
@yoaquim thanks. extensions worked
@deiga's and @yoaquim's suggestions worked perfectly. Just need to add the appropriate extension in the filename.
Not alvays is good to add extension to perl or shell scripts in linux.
~~I think the expected behavior is that the language setting works regardless of file name/extension.~~
I don't think this is a bug with this plugin. When creating Gist manually, if I don't specify an extension github reverts back to text, no matter what language I specify.
Oops, I'm not where I thought I was. My issue is with Gist, itself.
Same issue as described by others. Gist's always end up as Text for format. Chrome v37.0.2062.122
Still not working. Using Opera 12.16 and Opera Developer 26 @ Linux Mint 17. Please, fix this. Thanks!
There is definitely still a language selection issue. My gist (https://gist.github.com/gabe19/f6d0590d77909f28fd3b) keeps some of the files as "Smalltalk" even though I never selected this and the files have the .cs extension. The language will be correctly auto-selected to C# when I edit the file but it doesn't hold.
I've had the same issue with some ObjC gists I've been creating, added the .m and it worked but I've got older gists with no file extension that saved fine
[Using Safari Version 8.0.2 (10600.2.5)]
Two problems still exist for Chrome latest (public gists).
- Unable to use custom extension. When i change file name to a xxx.conf, A javascript sets language option to Apacheconf, even if i have changed it to Nginx. then it ignores completes. syntax highlighting also
- Language option can not be saved when we edit the gist. When in editing gists. whichever option you change the language. it just ignores & saves as "text".
@risyasin I can confirm the second problem is also the case in Safari 8.0.4 , Mac OS X Yosemite 10.10.2.