fix clojure keywords highlighting in sublime text - clojure

Is there anybody here who knows how i can fix clojure keywords highlighting in sublime text?
:keyword
I probably need to modify Clojure.tmLanguage in the Clojure package, but it is a bit intimidating
It should be easy because, it just need to match all words that begin with colon but i can't figure out how to do it myself...
function names containing arrows are not well highlight neither
(defn foo->bar ...)
Any help will be welcome

I just released a new version of the Neon Color Scheme that includes expanded syntax highlighting for Clojure, including :foobar symbols. You can install it via Package Control.

Related

How to find non localised strings in a swift project

How can I find all strings a project that are not being localised?
My goal is to add support for localisation by generating the XLIFF file, via Editor->Export For Localisation. In order to do that, I first added comment for Localiser where needed in the Storyboard.
Next, I need to find in the code all Strings that do not use NSLocalizedString("...", comment:"...").
Is there a way to find all these strings?
I didn't succeed writing a regex to find them, due to my lack of competence in regex.
My goal is to have a regex like this:
[withIdentifier: |NSLocalizedString(]".*"
in order to find all strings surrounded by quotes, and that are not precedeed by some keywords.
I tried with no success using negative look ahead with
A regular expression to exclude a word/string
It's not meant for automated replacement, but just to have a quick view if I haven't forgotten some strings.
Thank you very much!
OBJC
There is a possible way that you can find ALL The Strings which are not used by NSLocalizedString
Goto Product -> Analyze
From Left Panel you can see
Where you can find each and every string which are not Localized
On tap on that
XCode will tell you issue
SWIFT3
I am not Sure about solution NOT TESTED
https://medium.com/#pinmadhon/finding-non-nslocalized-strings-in-xcode-8-in-swift-3-or-objc-589ee279a166

How to match and replace n number of times with RegEx

I'm using TextWrangler, the free version of BBEdit on the Mac, which I understand uses the PCRE engine.
What I want to do is match a specific number of lines and replace as well.
After a lot of searching I came up with this:
(^(.*\r)){25}
This lets me match up to 25 lines. It works great, but the problem comes when I want to actually replace something. I can't figure out how to do it.
For example, I would like to replace all of the returns "\r" with tabs "\t".
Hopefully this is actually possible. I'd appreciate any help. Thanks!
Regexp domain is searching. You cannot replace using regexp; a programming language or editor can use regexp as the search part of its search-and-replace function. Thus, the way to do 25 replacements is purely in the domain of said programming language or editor. If it does not provide such capability, either directly in search-and-replace or as a macro/loop/other, then you cannot do it automatically.

How to remove emoticons from tweets in C++?

I'm working on a twitter sentiment analysis tool in C++. So far I get the tweets from Twitter and I process them a bit ( lowercase, remove RT, remove # and URLs).
The next step is to remove emoticons and all those special characters. How does one do that? before you jump me, I already looked at other similar questions but none of them deals with C++. Mostly R,Python and PHP.
I was thinking to use regex however I can't get it to work. I tried it with removal of hashtags and URLs and I gave up. I ended up using normal string:find and find_first_of.
Is there any library or method available to get rid of those emoticons and special stuff ?
Thanks
I would recommend using regular expressions for this. Now you have two options, you can either extract only the characters you are interested in (if you are working with English tweets this would probably be A-Z,a-z, numbers and maybe some symbols, depending on your needs), or you can select invalid characters (emoticons) and replace them with an empty string.
I only have experience with Qt's RegularExpression engine, but the c++ standard library has regex support (although I'm not sure how good it is with Unicode), but the ICU provides a regex library too.
*I'd provide more links but I don't have enough reputation yet :/

RegEx with Excel VBA on Mac

I need to use regEx with Excel VBA. I'm using Mac OS 10.10 and Office 2011. So there is no DLL file I can use.
What is there to do here?
I read I've to bind an apple script. How is this done and what content does this script need?
You can use VBA's Like operator. It's a very limited regex tester only.
Microsoft Word has it's standard wildcards plus if you tick Use Wildcards it is a Regex engine (plus find words that sound the same, and words with the same root). So use Word rather than Vbscript's RegEx.
Just record a Find and Replace in Word and you'll get most of the program written for you that you'll just need to adapt.
Natively, you can't really - AppleScript isn't actually that good for this kind of thing (where VBA is concerned)
There are other libraries that you can install and use to allow support for things like regular expressions on Mac OS - the one I've seen used the most is Satimage although I've not personally had to use it (yet) so can't vouch for it myself:
http://www.satimage.fr/software/en/downloads/downloads_companion_osaxen.html
I'm working on this problem too and I think Advanced Filters may be your answer if you want to do it in Excel without adding an external library. You can access it through VBA and set up a hidden sheet somewhere to stash your filters.
https://searchengineland.com/advanced-filters-excels-amazing-alternative-to-regex-143680
And you can see what it looks like in VBA here:
https://www.contextures.com/exceladvancedfiltervba.html
However, Advanced Filters does have some notable shortcomings, like the inability to distinguish a digit from a letter. The LIKE command mentioned earlier DOES have this ability however - so you could combine them to overcome that limitation.
Hopefully you and I can both solve this problem using these tools...!

Eclipse search multiple strings in any order, case insensitive

I think the title is pretty self-explanatory. I have a big project in Eclipse Juno CDT and I want to search the whole workspace for matches to the strings 'max' 'hfr' & 'fps'. For a successful match they must all be on the same row, in any order, case or count. They can be part of words (variable names), so it is not exactly a word search.
Is this a job for regex, and what regex exactly? Or is there a hidden search feature in Eclipse that can let me do that easily?
If I understood well what you want to do. You simply need to use the eclipse search tool with regular expression (CTRL + H or Search>Search in eclipse menu). You'll see there's a lot of option and possibilities to configure your research, including using regular expression. You just need to construct the right regexp.
I hope this will help.