Script used unload and load usb driver in Mac for Asix AX88179 based Network adapter.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
source.sh | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var app = angular.module("webapp", []); | |
/** | |
* MustacheTemplater is a simple and small templating designed to | |
* generate simple text containing mustache quoated params. The template | |
* is defined using <script> tag with type of "text/ng-template". | |
* | |
* It is intentionally kept simple supporting only key value pares. Need | |
* additional logic? Use the mustache library instead. | |
* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
define(['angularAMD', 'angular-route'], function (angularAMD) { | |
var app = angular.module("webapp", ['ngRoute']); | |
app.config(function ($routeProvider) { | |
$routeProvider | |
.when("/home", angularAMD.route({ | |
templateUrl: 'view_home.html', controller: 'HomeCtrl', controllerUrl: 'controller_home' | |
})) | |
.when("/view1", angularAMD.route({ | |
templateUrl: 'view_view1.html', controller: 'View1Ctrl', controllerUrl: 'controller_view1' |
Sample code for on how to lazy load state for ui-router
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var b = {}, priv = 0; | |
b.valueOf = function () { | |
return priv += 1; | |
} | |
if ( b==1 && b==2 & b==3 ) { | |
console.log("This can only be true in JS!!!"); // This works!!! | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# | |
# Generic file to start and stop server using nohup and pid file | |
# | |
# Author: Marcos Lin | |
# Date: 15 Dec 2014 | |
# License: MIT License | |
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env kscript | |
/** | |
* Define a Printer class that will prefix the message with given | |
* symbol and apply a `postfix` to the end of the message. | |
* | |
* The methods will be available for the inline function | |
*/ | |
class Printer(private val postfix: String) { | |
fun asterix(message: String) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package app.fp8.beam | |
import org.apache.beam.sdk.Pipeline | |
import org.apache.beam.sdk.transforms.Create | |
import org.apache.beam.sdk.transforms.DoFn | |
import org.apache.beam.sdk.transforms.ParDo | |
import org.apache.beam.sdk.values.KV | |
import org.junit.jupiter.api.Test | |
import org.junit.jupiter.api.Assertions as assert |