Skip to content

Instantly share code, notes, and snippets.

schwarzeni

Block or report user

Report or block schwarzeni

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@rudolfratusinski
rudolfratusinski / parallels_tools_ubuntu_new_kernel_fix.md
Last active Aug 23, 2019
Parallels Tools fix for Ubuntu 18.04 and other Linux distributions with Kernel version >= 4.15
View parallels_tools_ubuntu_new_kernel_fix.md

Preparation

  • In open Ubuntu 18.04 machine click Parallels Actions -> "Install Parallels Tools"

  • A "Parallels Tools" CD will popup on your Ubuntu desktop.

  • Open it by double mouse click, copy all the content to a new, empty directory on a desktop, name it for e.g. "parallels_fixed"

  • Open terminal, change directory to parallels_fixed (cd ~/Desktop/parallels_fixed)

  • Make command line installer executable (chmod +x install)

  • Change directory to "installer" (cd installer)

  • Make few other scripts executable: chmod +x installer.* *.sh prl_*

@vbelcik
vbelcik / dropdown.directive.ts
Created May 15, 2017
Angular4 dropdown directive for bootstrap - enhanced
View dropdown.directive.ts
import { Directive, HostListener, HostBinding, OnDestroy } from '@angular/core';
@Directive({
selector: '[appDropdown]'
})
export class DropdownDirective implements OnDestroy {
private timer = null;
private isMouseInside: boolean = false;
@HostBinding('class.open') isOpen: boolean = false;
@wesleyegberto
wesleyegberto / web.xml
Created Mar 7, 2017
web.xml for Servlet 3.1
View web.xml
<web-app xmlns="http://xmlns.jcp.org/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee
http://xmlns.jcp.org/xml/ns/javaee/web-app_3_1.xsd"
version="3.1">
</web-app>
@AlexisLeon
AlexisLeon / rn.input-numbers.js
Created Jan 15, 2017
TextInput accepts only numbers - React Native
View rn.input-numbers.js
import React, { Component } from 'react';
import { TextInput } from 'react-native';
class Input extends Component {
constructor(props) {
super(props);
this.state = {
text: ''
};
}
@wycliffepeart
wycliffepeart / merge-object.js
Last active Jul 9, 2018
Javascript Object.assign Alternative . The mergeObject() method is used to copy the values of all enumerable own properties from one or more source objects to a target object. It will return the target object.
View merge-object.js
function mergeObject(target) {
for (var i = 1; i < arguments.length; i++) {
var source = arguments[i];
for (var key in source) {
if (source.hasOwnProperty(key)) {
target[key] = source[key];
}
}
}
return target;
@SimonSun1988
SimonSun1988 / gist:2ef7db45e46b889783647d941ec15e4d
Created Apr 12, 2016
解決 Ubuntu "can’t set the locale; make sure $LC_* and $LANG are correct" 的錯誤
View gist:2ef7db45e46b889783647d941ec15e4d
## 安裝語系檔
`$ sudo locale-gen "en_US.UTF-8"`
## 重新設定語系檔
`$ sudo dpkg-reconfigure locales`
## 設定檔
@subfuzion
subfuzion / curl.md
Last active Aug 24, 2019
curl POST examples
View curl.md

Common Options

-#, --progress-bar Make curl display a simple progress bar instead of the more informational standard meter.

-b, --cookie <name=data> Supply cookie with request. If no =, then specifies the cookie file to use (see -c).

-c, --cookie-jar <file name> File to save response cookies to.

@drewolson
drewolson / reflection.go
Last active Jul 17, 2019
Golang Reflection Example
View reflection.go
package main
import (
"fmt"
"reflect"
)
type Foo struct {
FirstName string `tag_name:"tag 1"`
LastName string `tag_name:"tag 2"`
@statianzo
statianzo / jade.vim
Created Nov 20, 2010
Jade syntax highlighting for vim
View jade.vim
" Vim syntax file
" Language: Jade
" Filenames: *.jade
" Ported from tvim-haml - https://github.com/tpope/vim-haml
" For use with Jade - http://jade-lang.com/
" Now maintained at: https://github.com/statianzo/vim-jade
if exists("b:current_syntax")
finish
endif
You can’t perform that action at this time.