Skip to content

Instantly share code, notes, and snippets.

#I'm trying to auto mount (on boot) external device (NTFS). The disk has two partitions.
#When I mount the sda1 partition only - it's OK, when I try to mount the second partition (sda5) -
#the system enters the "emergency" mode.
#Here are the results of
#df -h
#blkid
#and fnally my /etc/fstab file.
# -----------------------
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
var Utils =
function Utils() {
_classCallCheck(this, Utils);
$('.expander').click(function () {
console.log('test');
});
console.log('but yes, it is printed');
};
@konrados
konrados / es2015.js
Last active September 30, 2016 07:01
class Utils {
constructor() {
$('.expander').click(function(){
console.log ('test');
});
console.log('but yes, THIS sentence is printed');
}
}
var utils = new Utils();
My piece of "html5" class, which will then be "required":
---------------------------------------------------
<?php
class Utils {
constructor() {
this.callbacks = [];
//stuff
}
.babelrc file:
{
"presets" : ["es2015"]
}
class Utils {
constructor() {
//...
}
registerReadyCallback (callback){
//...
}
}
//...
<FilesMatch \.php$>
SetHandler application/x-httpd-php
</FilesMatch>
konrad@konrad-MS-7817 /v/w/h/analytics> git svn dcommit
Committing to http://192.168.1.253/svn/analytics/trunk ...
at /usr/lib/git-core/git-svn line 1836.
main::get_commit_entry("88b8cbc109602d7ed7570cab6735662de93d7fb6") called at /usr/lib/git-core/git-svn line 1007
main::cmd_dcommit() called at /usr/lib/git-core/git-svn line 386
eval {...} called at /usr/lib/git-core/git-svn line 384
@konrados
konrados / story.txt
Last active September 19, 2016 09:12
Not my story:
I worked for a while for a (now defunct) search engine company whose middleware had been written
by an insane person (about 5000 Java source files) who had moved on. Some of the characteristics:
Most methods began with for(;;) so that continue statements could be used as gotos
Almost all methods returned an object which wrapped an int, a string, a boolean and an object array,
so the return type could be changed later (and woe be unto any code using the return value).
<?php
private function connect($dsn)
{
//it's ok, it prints out
echo $this->username;
//it prints out, also OK
echo '<br>'.$this->password;
//an empty array
var_dump($this->connectionOptions);
try{