recentpopularlog in

kme : language   342

« earlier  
yum - How to add language support on CentOS 7 (on Docker)? - Server Fault
If they'd just stop saying 'localectl' is the solution, when it doesn't work in Docker. There's no DBus daemon running or something. The 'systemctl' command doesn't work, even. These things are stripped out in container environments, I guess.

What *actually* works is
<code class="language-bash">yum reinstall -y glibc-common</code>
and then setting 'LC_ALL` or 'LANG` in the environment.
centos  centos7  locale  docker  language  characterencoding  maybesolution 
june 2019 by kme
How to Set Up System Locale on CentOS 7 | RoseHosting
I think 'localectl' is not built into the base CentOS 7 OS or something? Or at least not the Docker image? Because, sure enough, it wasn't there before, and after a 'yum update' it is.

For a CentOS 7 Docker image, however, you still need to 'yum reinstall -y glibc-common' and just set 'LC_ALL' or 'LANG' in your environment; the 'localectl' command won't work because there's no D-Bus daemon running on the Docker image.
centos  locale  language  sysadmin  sortof  solution  docker 
june 2019 by kme
GitHub - tree-sitter/tree-sitter: An incremental parsing system for programming tools
An incremental parsing system for programming tools - tree-sitter/tree-sitter
programming  language  parser  library 
june 2019 by kme
Want a New Emoji? Good Luck. - by Andy Warner
How a nearly invisible cabal of tech industry leaders controls what you can and can’t type 🤔
emoji  unicode  language  journalism  cabals  cartoon  webcomic  explained 
june 2019 by kme
GitHub - btford/write-good: Naive linter for English prose
Naive linter for English prose. Contribute to btford/write-good development by creating an account on GitHub.
english  language  grammar  writing  linter  stylechecker  nodejs  npm 
june 2019 by kme
Dry Run « The Word Detective | http://www.word-detective.com/
Beginning in the late 19th century, fire departments in the US began conducting practice sessions where engines were dispatched and hoses deployed, but water was not pumped, thus making the exercises literally “dry” runs. Public exhibitions and competitions between departments also typically centered on such “dry runs.” Conversely, a real run to a “working fire” where water was pumped was known as a “wet run.” In his posting to the ADS list, Doug Wilson found instances of this use of “dry run” dating back to 1893. Just when the term came into more general use meaning “practice session” is uncertain, but it seems to have been after “dry run” was widely used in the US Armed Services during World War II.
english  language  idiom  colloqualism  solution 
may 2019 by kme
cheatsheets/base-r.pdf at master · rstudio/cheatsheets | https://github.com/
RStudio Cheat Sheets. Contribute to rstudio/cheatsheets development by creating an account on GitHub.
r  language  cheatsheet  reference 
may 2019 by kme
STHDA - Home | http://www.sthda.com/
STHDA is a web site for statistical data analysis and data visualization using R software. It provides many R programming tutorials easy to follow.
stats  visualization  r  language  programming  newbie  tutorial  reference 
march 2019 by kme
About the WWP | https://wwp.northeastern.edu/
The Women Writers Project is a long-term research and publication project focusing on early women’s writing in English. We have been working since 1988 on building an electronic collection of rare and less familiar texts, and on researching the complex issues involved in representing early printed texts in digital form.
womenin  literature  english  language  corpusanalysis  repository 
february 2019 by kme
Alex - Catch insensitive, inconsiderate writing | https://alexjs.com/
Whether your own or someone else’s writing, alex helps you find gender favouring, polarising, race related, religion inconsiderate, or other unequal phrasing.
javascript  library  language  writing  censor  abuse  harassment 
january 2019 by kme
Big Huge Thesaurus: Synonyms, antonyms, and rhymes (oh my!) | https://words.bighugelabs.com/
Get english synonyms, antonyms, sound-alike, and rhyming words from the Big Huge Thesaurus.
language  dictionary  thesaurus  reference  webservice  rest  api  poetry  writing 
january 2019 by kme
Dispatch in Two Parts: The Arab Body Writes Itself In | Boston Review | https://bostonreview.net/
In a recent Guardian interview the Libyan-British writer Hisham Matar says, “International literature remains hugely underrated and, as a side effect, English books are often overrated. About 1.5% of books published in the UK and 3% of those published in the USA are works in translation. And the sales are often dismally modest. This impoverishes culture and nourishes narcissism. Put very simply, it is boring and dangerous.” Narcissim here can also be read as imperialism.
perspective  culture  colonialism  translation  language  poetry 
january 2019 by kme
Primer on Python Decorators – Real Python | https://realpython.com/
<code class="language-python">
def repeat(_func=None, *, num_times=2):
def decorator_repeat(func):
@functools.wraps(func)
def wrapper_repeat(*args, **kwargs):
for _ in range(num_times):
value = func(*args, **kwargs)
return value
return wrapper_repeat

if _func is None:
return decorator_repeat
else:
return decorator_repeat(_func)
</code>
python  newbie  language  idiom  decorators  solution 
november 2018 by kme
What are your thoughts on sigils? : perl | https://www.reddit.com/
Larry Wall notes in an interview that «On a syntactic level, in the particular case of Perl, I placed variable names in a separate namespace from reserved words. That's one of the reasons there are funny characters on the front of variable names -- dollar signs and so forth. That allowed me to add new reserved words without breaking old programs.». Furthermore, first order lists allow for cleaner code sometimes. So I think sigils are great, but naturally inexperienced people often complain that they add clutter or make the code "unreadable" or "messy".

And I find that sigils give my code more visual rhythm and makes it easier to read


This, right here.

I don't need a fancy IDE or somehow encoding the type of the thing into the name of the thing to know what it is. Or, at least, the type of thing that the author wanted the interpreter to treat it as.

Having spent the last couple years in node/javascript land, too often it's a "oh, shit, it's a function?" is too common.
perl  language  design  perl5  syntax  thisvsthat  forthecomments  sigils 
september 2018 by kme
centos5 - How do I change my locale to UTF-8 in CentOS? - Server Fault | https://serverfault.com/
In CentOS try with system-config-language command. That's the CentOS way :) Also you can try with:
<code class="language-bash">
localedef -c -f UTF-8 -i de_DE de_DE.UTF-8
export LC_ALL=de_DE.UTF-8</code>
locale  centos  aufdeutsch  language  i18n  solution 
may 2018 by kme
set locale on commandline without system-config-language - CentOS | https://www.centos.org/
So... there is basically no good solution for this out of the box? A CentOS 7 Docker container has the same problem.

<code class="language-bash">yum whatprovides \*/setlocale</code>
centos  language  locale  i18n  interesting  sysadmin 
may 2018 by kme
How to prevent overwritting Python Built-in Function by accident? - Stack Overflow | https://stackoverflow.com/
You can't. You could use linters (e.g. pylint) which will check for this kind of thing, but Python allows you to reuse anything except a keyword (https://docs.python.org/2/reference/lexical_analysis.html#keywords) or None.
You can't prevent it, Python is built on the notion of "we're all consenting adults" so you are free to do what you want. It is possible to delete the override but you'd have to know that you shadowed that function in the first place.
python  language  syntax  newbie  pitfall  annoyance  explained 
april 2018 by kme
Matthew Anderson on Twitter: "Things native English speakers know, but don't know we know:… "
It's from The Elements of Eloquence: How to Turn the Perfect English Phrase by Mark Forsyth
english  language  nativespeakers 
january 2018 by kme
Go Ahead, Put that Preposition at the End! | https://www.dailywritingtips.com/
This is the kind of arrant pedantry up with which I will not put. --Churchill

Those who lay down the universal principle that final prepositions are “inelegant” are unconsciously trying to deprive the English language of a valuable idiomatic resource, which has been used freely by all our greatest writers except those whose instinct for English idiom has been overpowered by notions of correctness derived from Latin standards.

The legitimacy of the prepositional ending in literary English must be uncompromisingly maintained; in respect of elegance or inelegance, every example must be judged not by any arbitrary rule, but on its own merits, according to the impression it makes on the feeling of educated English readers.
english  language  writing  style  grammar  solution 
january 2018 by kme
Perl Debug session dies in Heavy.pm | http://forums.devshed.com/
As Professor Tennenbaum warned his Brooklyn College classes, programming languages can be every bit as silly a arbitrary as human languages.
perl  errormessage  programming  language  wisdom 
january 2018 by kme
Ruby-Doc.org: Documenting the Ruby Language
Why isn't this more prominently linked from ruby-lang.org?
ruby  programming  language  reference  newbie  documentation  devel 
december 2017 by kme
Where Tcl and Tk Went Wrong (2010) | Hacker News | https://news.ycombinator.com/
I've read that he'd wanted to just use Scheme, but that they needed the language to have "Java" in the name, as well as curly braces. So, we got Javascript.

Also, given that DSSSL was an early contender against CSS (and a great deal more powerful), we could have basically had Scheme there too. https://blog.cloudflare.com/the-languages-which-almost-becam...

Lastly, because S-expressions can represent everything that is representable in SGML/XML/(X)HTML, but more succinctly, we could have basically had Scheme instead of HTML.

Imagine if, instead of JS/HTML/CSS, we had... Scheme. I'm pretty sure that the alter universes where this happened also all have peace, warp drives, and working cold fusion.


From Eich:
Study history or you, too, may be doomed to repeat it:

https://devchat.tv/js-jabber/124-jsj-the-origin-of-javascrip... (transcript at bottom)

https://brendaneich.com/2012/04/the-infernal-semicolon/#comm...

Netscape management gave "make it look like Java" orders. There was no time, on top of this. Last (more below in another reply) no extant command line interpreter was ready to be put in a browser. Way too many non-portable OS dependencies, unsafe FFI, etc. It was JS or bust (aka VBScript).

Thats actually not totally true. Internally, Tcl has two value types, string representation and actual value representation. Everything DOES have a string-representation though- some are made up (like file handles, fileX) and some are just ASCII forms of the values underneath (like integers).

Tcl is cool because you can manipulate the string form of values incredibly easily, but people confused this with "Everything is a string". It should be "Everything can be manipulated like a string".
tcl  programming  scripting  language  thestoryof  alsoran  vs  javascript  theweb 
november 2017 by kme
Flash is Dead: What Technologies Might Be Next? - Stack Overflow Blog | https://stackoverflow.blog/
This sudden shift in Flash’s fortune suggests there’s truth to the conventional wisdom that Apple “killed” Flash by not supporting it on the iPad in 2010.
flash  perl  dyingtechnologies  programming  language  webdevel 
november 2017 by kme
function - What is the JavaScript convention for no operation? - Stack Overflow
To answer the original question, the most elegant and neat implementation of a noop function in pure Javascript (as is also discussed here) is Function.prototype.

The snippet below shows its usage:

<code class="language-javascript">
setTimeout(Function.prototype, 10000);
</code>
javascript  syntax  newbie  language  solution 
october 2017 by kme
Why isn’t there a switch or case statement in Python? - Design and History FAQ — Python 2.7.14 documentation | https://docs.python.org/
You can do this easily enough with a sequence of if... elif... elif... else. There have been some proposals for switch statement syntax, but there is no consensus (yet) on whether and how to do range tests. See PEP 275 for complete details and the current status.

For cases where you need to choose from a very large number of possibilities, you can create a dictionary mapping case values to functions to call. For example:

def function_1(...):
...

functions = {'a': function_1,
'b': function_2,
'c': self.method_1, ...}

func = functions[value]
func()

For calling methods on objects, you can simplify yet further by using the getattr() built-in to retrieve methods with a particular name:

def visit_a(self, ...):
...
...

def dispatch(self, value):
method_name = 'visit_' + str(value)
method = getattr(self, method_name)
method()

It’s suggested that you use a prefix for the method names, such as visit_ in this example. Without such a prefix, if values are coming from an untrusted source, an attacker would be able to call any method on your object.
python  language  syntax  newbie  faq  butwhy 
october 2017 by kme
Why We Created Julia
While we’re being demanding, we want something that provides the distributed power of Hadoop — without the kilobytes of boilerplate Java and XML; without being forced to sift through gigabytes of log files on hundreds of machines to find our bugs.
julia  multiprocessing  parallelism  programming  language  design 
april 2017 by kme
« earlier      
per page:    204080120160

Copy this bookmark:





to read