Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Syntax highlighting enabled for languages other than Objective-C #79

Open
wants to merge 7 commits into
base: experimental
Choose a base branch
from

Conversation

suranyami
Copy link

Hi. I've made a few changes that enable syntax highlighting for languages other than Objective-C.

It needed all of the brush javascript files to be imported into:

`html/views/fileview/index.html`

passing the full file path into showFile from GLFileView.m

and some javascript string manipulation in

`html/views/fileview/fileview.js`

This is based on commit 9dd29f6

I've built and tested it locally using Ruby files and it seemed to work fine. I'm not an expert on Objective-C, though, so don't be surprised if I've not cleaned up a pointer or somesuch.

Also added a Hash of suffix -> brush mappings, so that the right brush will be applied to file type.

Thanks for your fabulous work with GitX, btw. Our team uses it every day, and couldn't live without it.

we can use the file suffix to determine which syntax highlighting to use.
Added a hash of possible values to select the correct brush based on the suffix.
This fixes a problem where some suffixes did not match brush aliases.
@laullon
Copy link

laullon commented Dec 6, 2010

I've merged yours commits to my master branch, this was on my todo-list ;)
Good work.

kelan pushed a commit to kelan/gitx that referenced this pull request May 15, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants