how to set unix/bash as default language on notepad++ 6.5.5 - bash

when going in settings> preferences> new document, which language should I chose to create Unix scripts (*.sh *.bsh).
I know that a solution is to chose the format when saving, but it's kinda annoying...
thanks!

Format: Unix/OSX
Default language: Shell
Encoding: UTF-8 without BOM

At the bottom of Notepad++ -status bar- you will see that 7th and 8th columns are describing the format of the file you are editing.
double click on the 7th one and select "Unix(LF)"
for the 8th one Go To: Encoding -> Encode in UTF-8

Related

How to set default unicode of notepad to UTF8?

Every time I'm saving a file that has some Unicode characters in
notepad, it prompts me that this file is going to be saved in ansi
format and you will losing some data and I should cancel saving
and choose UTF8 as unicode.
How can I set default encoding to UTF8 so it will not prompt me every time?
thanks in advance.
In windows 10, get to
Control Panel > Region > Tab Administrative
Hit button "Change system".
Then choose the language you use from the combobox labeled "Current system locale".
And check the checkbox labeled "Beta: Use Unicode UTF-8 for worldwide language s".
Hit the ok button.
Short answer - Notepad simply does not support what you are asking for. It will always default to ANSI, you have to tell it explicitly not to use ANSI. However, there are alternatives available, see Changing the default ANSI to UTF-8 in Notepad on SuperUser.

Converting unicode characters to the readable format with Emeditor?

I have a huge file with many unicode (C/C++/Java) characters like that :
\u00e9
\u00e8
\u00e2
Is there a one click way to convert all those characters to the readable format ?
(e.g : \u00e9 to é)
Thank you in advance.
Press Ctrl+A to select all text to convert, and then select the Edit menu - Encode/Decode Selection - Universal Character Names to Unicode.

How to insert/copy+paste unicode whitespace into a text file using editors like Textmate?

I am trying to create a test csv file for a file cleaning script that is supposed to normalize all whitespace into "normal"/ "regular" whitespace character. The idea is I will insert a bunch of these oddball whitespace characters into this test file in some various locations.
Here are some sites that show these various and oddball whitespaces
https://en.wikipedia.org/wiki/Whitespace_character
http://jkorpela.fi/chars/spaces.html
I've tried to copy and paste from sources like that website but it seems like they always paste in as a normal space in Textmate. It could be that I am not copying what I think I am copying. In the past I've been able to copy and paste into Textmate special / unicode characters when I can clearly see what I am copying but with whitespace characters, I can't confirm since I can can't see it, so I am not sure if the problem is where I am copying from or that Textmate is converting it to the normal space when I paste it in.
If it is easier to use Textedit (the built in editor) or nano (command line editor) to do this I could use those. Or if there is another way other than copying and pasting that is better to get these into Textmate that would be an option.
I am on a MacbookPro running High Sierra MacOS.
If you have LibreOffice installed you can use the spreadsheet application to create these using their hexidecimal equivalent in 1 cell then doing a conversion using
=unichar(hex2dec(cell_ref_to_1rst_cell)).
Far less confusing and you can save the spreadsheet complete with comments as a handy reference. Then you should just be able to copy paste the cell with the unicode character when required.
If you’re using TextMate, various functions provided by the Unicode bundle could be helpful here (install via Preferences → Bundles → Unicode).
With this bundle installed you can use Insert Unicode Character ⌃⌥⌘I to insert a character by name. Search for “space” to get a list of all space characters, then simply click on the desired character (the full title of a character is shown on hover):
Of course once inserted all the space characters look almost identical. To identify them, use Show Unicode Name(s) ⌃⌥⌘U 6. This will display a tooltip showing the unicode of name of the character directly before the cursor (or the names of all selected characters, if a selection is active).
Also have a look at Show Character Inventory (press ⌃⌥⌘U and then select the command from the popup menu): This provides a convenient overview of all the characters in your document (or in the selected text, if a selection is active).

How to disable formatting in TextEdit on Mac Yosemite

When I copy something and paste it from buffer in TextEdit, it saves text formatting (font-color, background-color, font-style) How can I turn that off?
I don't think you will be able to turn it off. But you can tweak it in the copy/paste process.
Take a look at this article here as it explains how you can copy/paste using a certain combination of keys to skip formatting.
Paste the copied text and match current style by using Command+Option+Shift+V.
Notice the difference from the normal Command+V paste trick, which would include the formatting.
If you don't want to save text with formatting, you should work with plain text format: menu Format > Make Plain Text (⇧⌘T). You can also set plain text format as your default document format in TextEdit Preferences.

vim powerline in windows 7

I am trying to install VIM Powerline on window, I found a comment which supposed to fix how it looks in Windows, but encoding of the comment is broken by itself...
The link to the blog post.
I had the same problem on windows. As an alternative to editing “vim-powerline-develop\autoload\Powerline\Functions.vim”, you can also add this to your vimrc:
let g:Powerline_mode_V=”V·LINE
let g:Powerline_mode_cv=”V·BLOCK”
let g:Powerline_mode_S=”S·LINE”
let g:Powerline_mode_cs=”S·BLOCK”
I don't know how to type the cdot operator in my keyboard (sorry for the name, I guess I am too much into Latex ...).
So, what am I supposed to do to make VIM behave under windows?
To get the middle dot, the easiest and pragmatic way would be just pasting it from the clipboard.
For direct text entry, you can enter by the character encoding's numerical value: <C-v>183, see :help i_CTRL-V_digit. On Windows, you often need to use <C-q> instead of <C-v>.
Vim also has a feature called digraphs for quick entry of special characters. The middle dot would be <C-k>.M.
For any of these to work, your text encoding must support the non-ASCII character. Best use a value of
:set encoding=utf-8
and ensure that your ~/.vimrc is UTF-8 encoded.

Resources