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

Epitech header's dates are dependent on locale #8

Open
juliencampion opened this issue May 27, 2015 · 7 comments
Open

Epitech header's dates are dependent on locale #8

juliencampion opened this issue May 27, 2015 · 7 comments

Comments

@juliencampion
Copy link

Here's how my Epitech header (created with vim-epitech) looks:

/*
** exec_type.c for 42sh in /home/julien/projets/epitech/B2/42sh/rendu/src/pline
**
** Made by Julien Campion
** Login   <[email protected]>
**
** Started on  mar. mai 12 10:56:39 2015 Julien Campion
** Last update dim. mai 24 13:33:36 2015 Julien Campion
*/

Notice how the creation and modification dates on my header are in French, because my system locale is in French. Or, as I understand it Epitech's C header should look exactly like the Emacs one, where the dates are in English.
Is there any way for me to output the date in the correct format without having to change my system locale to do so?

@casimir
Copy link
Collaborator

casimir commented May 27, 2015

You can change your editor's locale, language time en_US.utf-8 should do the trick.

@juliencampion
Copy link
Author

Sorry for the long delay to answer.

Yes it worked perfectly. But I'm also thinking of other people who would like to keep their language settings set to default and output english date text only for the Epitech header. Isn't there a way to only output the time in English in the plugin files and to be able to keep one's current locale outside the plugin?

@casimir
Copy link
Collaborator

casimir commented Jun 1, 2015

Should be fixed with dc09994. If no en_US locale is present on the system it should fallback to C.

@juliencampion does it fix it?

@juliencampion
Copy link
Author

It worked only when I replaced 'en_US' in header.vim with 'en_US.utf-8'.

I removed the en_US locale and tried again but the script told me 'Could not choose language: en_US.utf-8'.

@casimir
Copy link
Collaborator

casimir commented Jun 1, 2015

What do you get with language time afterwards?

@juliencampion
Copy link
Author

"fr_FR.UTF-8"

@juliencampion
Copy link
Author

Oh by the way 'en_US' is still not replaced with 'en_US.utf-8' in header.vim.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants