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
apps = {} | |
apps.launchers = { | |
{ | |
name="Home - Coding", | |
description="Launch apps for coding.", | |
apps={ | |
"Sublime Text", | |
"iTerm", | |
"Dash" |
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
{ | |
"global": { | |
"check_for_updates_on_startup": true, | |
"show_in_menu_bar": true, | |
"show_profile_name_in_menu_bar": true | |
}, | |
"profiles": [ | |
{ | |
"complex_modifications": { | |
"parameters": { |
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
<platform_solution><objects><form_script><parameters></parameters><name>setProjectRiskInformation.js</name><association>project_edit_form</association><event>after_save</event><libraries></libraries><comments></comments><code><![CDATA[/** | |
* Copyright NetSuite, Inc. 2014 All rights reserved. | |
* The following code is a demo prototype. Due to time constraints of a demo, | |
* the code may contain bugs, may not accurately reflect user requirements | |
* and may not be the best approach. Actual implementation should not reuse | |
* this code without due verification. | |
* | |
* Set the risk profile of a project using a custom field. | |
* | |
* Version Date Author Remarks |
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
/** | |
* Main entrance function (afterSave) | |
*/ | |
function main(type) { | |
var DECIMALS = 2; | |
var FLD_RATE = 'budget_rate__c'; | |
var needsUpdate = false; | |
var newRec = NSOA.form.getNewRecord(); | |
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
# Calculate Business Days (does not include start date) | |
CASE WHEN (TO_CHAR({systemnotes.date},'J') - TO_CHAR({created},'J'))+1 - ((((TRUNC({systemnotes.date},'D'))-(TRUNC({created},'D')))/7)*2) - (CASE WHEN TO_CHAR({created},'DY','nls_date_language=english')='SUN' THEN 1 ELSE 0 END) - (CASE WHEN TO_CHAR({systemnotes.date},'DY','nls_date_language=english')='SAT' THEN 1 ELSE 0 END) = 1 THEN 'Same Day' WHEN (TO_CHAR({systemnotes.date},'J') - TO_CHAR({created},'J'))+1 - ((((TRUNC({systemnotes.date},'D'))-(TRUNC({created},'D')))/7)*2) - (CASE WHEN TO_CHAR({created},'DY','nls_date_language=english')='SUN' THEN 1 ELSE 0 END) - (CASE WHEN TO_CHAR({systemnotes.date},'DY','nls_date_language=english')='SAT' THEN 1 ELSE 0 END) = 2 THEN 'Next day' ELSE CONCAT((TO_CHAR({systemnotes.date},'J') - TO_CHAR({created},'J'))+1 - ((((TRUNC({systemnotes.date},'D'))-(TRUNC({created},'D')))/7)*2) - (CASE WHEN TO_CHAR({created},'DY','nls_date_language=english')='SUN' THEN 1 ELSE 0 END) - (CASE WHEN TO_CHAR({systemnotes.date},'DY','nls |
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
# https://stackoverflow.com/a/19236791 | |
ssh pi@ip_address -R 52698:localhost:52698 | |
# to open a file in Sublime Text | |
rsub filename.txt |
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
export VISUAL=nano; crontab -e |
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
# run python terminal-less in the background | |
$ nohup python overcast-sonos.py | |
# to find the PID, run this | |
$ pgrep -f "overcast" | |
# to kill the process, run this | |
$ pkill -f "overcast" |
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
# Human readable output flag | |
$ df -h | |
# Filesystem Size Used Avail Use% Mounted on | |
# /dev/root 6.0G 4.4G 1.4G 76% / | |
# devtmpfs 428M 0 428M 0% /dev |
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
.pre-block | |
{ | |
background: @terminal; | |
.border-radius(6px); | |
padding: 1px 20px; | |
margin: 40px auto; | |
width: 500px; | |
.box-shadow(0px 1px 8px darken(@white, 30)); | |
position: relative; | |
color: @white; |