Tuesday, February 7, 2017

Slack Shortcut: Search for a Person or Group

GOAL
Search for a particular person or group or channel in Slack with a keyboard shortcut.  This shortcut is specific to Mac.

KEYBOARD SHORTCUT

Command + K

Monday, October 17, 2016

Digitize Your Handwriting into a Font


GOAL:  Digitize your handwriting and turn it into a font.  Made possible by www.MyScriptFont.com.

STEPS

1.  Print this template and fill out all of the squares with a black marker.

2. Scan it as a Photo (at 300 dpi) in grayscale, not color.  Save as JPG.

3. Upload the JPG, PNG, or PDF template to www.MyScriptFont.com.

4. Choose .TTF file format + Download

5. Mac Steps: Go to Apps > Font Book

6. Drag & drop your .TTF file into the Font Book App

Now, open up Word and use your new font!

Friday, October 7, 2016

Copy Unique Values in Google Sheets


GOAL
Copy unique values from one column to another column in Google Sheets (or Excel).


SOLUTION

=UNIQUE(A1:A10)

A1:A10 is the range of cells you hope to narrow to only unique values


EXAMPLE
Column A:
Column B: Use this formula:
=UNIQUE(A1:A13)
and get the following:
Dogs
Dogs
Cats
Dogs
Dogs
Dogs
Cats
Snakes
Cats
Turtles
Dogs
Dogs
Cats
Dogs
Cats
Snakes
Turtles

Wednesday, September 7, 2016

Hover Text for HTML

GOAL:  Add "hover text" when a mouse hovers over a certain word in an HTML webpage.  

CODE
<p title="Hover Text"> Word <p>


EXAMPLE

Word

Hover over the "Word" above to see "Hover Text".  This is a very simple way of adding hover text using a native part of HTML:  the title attribute.  Note: You can use the "title" attribute with HTML text tags beyond <p> tag, such as <h1>, <h2>, <h3>.

Tuesday, September 6, 2016

Find Color Code of an Image on your Screen

GOAL:  Figure out the color code of something on your desktop screen so that you can use / reference that color in another app or site.  

STEPS

1. Download Color Picker App from Mac App Store

2. Open App & Click "Magnifying Glass" Button

3. Select the colored pixel on your screen that you'd like to reference

4. Copy HEX Code & Paste into another app or webpage


NOTE
This post is specific to MAC.  It can also be helpful for: 
- Finding a color to use when coding webpages
- Finding a color to use on a Google Slide


Monday, August 29, 2016

Cyberduck Permission Denied (Upload Failed in GUI, but not Terminal)

PROBLEM
Cyberduck "Upload Failed" in the Mac GUI.  Permission denied.

SOLUTION
Update Cyberduck to the latest version

STEPS
Cyberduck > Check for updates...


DETAILED PROBLEM 


Editing a file in the Cyberduck Graphical User Interface (GUI) resulted in "Upload Failed.  Permission Denied. Please contact your web hosting service provider for assistance.

Editing that same file through terminal in nano threw no permissions errors.

Specific to:

  • Mac
  • Cyberduck

Monday, May 2, 2016

Keynote Slides: Print Each Page of the Animation

GOAL:  Print each slide of a Keynote, including each step of all animations.

STEPS inside of Keynote

1. File
2. Export To > PDF...
3. Click the checkbox: "Print each stage of builds"

4. Next...
5. Export / Save
6. Open that PDF & Print

Monday, January 18, 2016

Youtube Link to a Specific Time

GOAL:  Send a link to a specific time in a youtube video.

STEPS

1.  Add  #t=10m11s  after your link

                 t = time, m = minutes, s = seconds

2.  Example:  https://www.youtube.com/watch?v=Hs6rzV8nsPY#t=24m35s 


This jumps the person opening the link to that exact minute and second of the video.

Upload Audiobook to Audible

GOAL:  Import or Upload an audiobook from a CD or MP3 to the Audible App.

STEPS


  1. Create an iTunes playlist called "Audiobooks"
  2. When syncing your iPhone to your computer:
    • Inside of the sync settings > under Book:Audiobooks
    • Select checkbox to sync books from that "Audiobooks" playlist
    • When iPhone is synced, the audiobooks transfer from your computer to your phone
  3. A new iTunes tab now automatically pops up in the "Audible" app



Friday, December 11, 2015

Re-Enable Widgets Dashboard in Mac El Capitan

GOAL:  Enable the widgets dashboard in Mac El Capitan.  Apple disabled by default, but the widgets can be re-enabled with steps below.

STEPS

1.  System Preferences

2.  Mission Control

3.  Dashboard dropdown:  choose "As Space"


RESULT
The furthest left most desktop will now show your widgets dashboard.  Example:




Thursday, September 10, 2015

Fix Gray Exclamation Point Triangle in Gmail

PROBLEM:  Gray exclamation point triangle is showing up in the middle of Gmail.

STEPS
1.  Setting gear  ( top right ) > Themes
2.  Select another theme

Close Tab in Google Chrome [Keyboard Shortcut]

Command + w

Closes tab directly with keyboard, without clicking the X in Chrome.
Specifically for Mac & Chrome.

Google Calendar: Keyboard shortcut to Save Event

GOAL:  Save a Google Calendar event from the details page with a keyboard shortcut.  

Command + s

This command saves this page without clicking:








Specifically for Mac & Chrome.
Reference

Sunday, August 2, 2015

BOOTCAMP missing from Finder in Mac OSX

PROBLEM:  BOOTCAMP is not showing up in Finder.  This is often after using the Bootcamp partition through your Windows Virtual Machine in Parallels Desktop or VMware.

SOLUTION

1. Search for the app:  Disk Utility

2.  Click on "BOOTCAMP" on left side panel (which is likely grayed out)


3.  Click "Mount" (at top)

4.  BOOTCAMP now shows up inside of Finder



Monday, June 22, 2015

Format JSON in Chrome

GOAL:  Format JSON files inside of Chrome.  Flat JSON files can often be really tough to scan through.  This will add hierarchy and color formatting to any JSON inside of Chrome.

STEPS

1.  JSONView: download from chrome web store

2.  + Add to Chrome > Checking... > Add

3.  Open JSON File (in Chrome) and view the hierarchical / colored formatting





Wednesday, April 22, 2015

Download Facebook Photo Album to Mac

GOAL:  Download all photos from 1 album in Facebook.  For Google Chrome & Mac specifically.

STEPS

1.  From Chrome > Open link to Download FB Album mod (chrome extension)

2.  "Add to Chrome"

3.  Go to your Facebook Album of photos to download

4.  Look for Facebook icon in URL bar & Click on it:

5. On pop-up > click blue "Normal" button

Note:  the chrome extension creates a custom webpage full of the photos from your one FB album.  Below, we'll save this webpage and all of its photos to your desktop.

6.  From this newly created webpage, type: Command + S

7.  Save As: Facebook-Album.html.  Format: Webpage, Complete.  Click "Save"

   
8.  The html & photos from that facebook webpage are now on your desktop in the Facebook-Album_files folder.

9.  Copy photos from the folder created on your desktop to your Mac Pictures folder of interest.

Thursday, February 26, 2015

Change Image on Select Dropdown HTML+JS

GOAL:  Switch out an image on a webpage based off of a select dropdown option. [HTML + JavaScript]

CODE
<select onchange="$('#imageToSwap').attr('src', this.options[this.selectedIndex].value);">
    <option value="http://cdns2.freepik.com/free-photo/facebook-logo_318-           49940.jpg" selected>Facebook</option>
    <option value="http://cdns2.freepik.com/free-photo/twitter-logo_318- 
    40459.jpg">Twitter</option>
    <option value="http://cdns2.freepik.com/free-photo/instagram-social-network-     logo-of-photo-camera_318-64651.jpg">Instagram</option>
</select>

<img id="imageToSwap" class="profile" src="http://cdns2.freepik.com/free-photo/facebook-logo_318-49940.jpg">

DEMO
See the Pen Change Image on Select Dropdown by Josh Wentz (@joshwentz) on CodePen.



Thursday, February 12, 2015

Compress Large PDF Files for Emailing [Mac]

PROBLEM:  PDF file is too large to email.
GOAL:  Compress large PowerPoint / Keynote files so that they can be easily emailed.

STEPS

1. In Mac, Open the "Preview" app

  • This process compresses the images in the document. The compressed images look the same as the originals when viewed onscreen, but they may be of lower quality when printed.

2.  Open the large PDF document

3.  File > Export...

4.  Quartz Filter dropdown:  change from None to "Reduce File Size"

5.  Save a document as a PDF file

Tuesday, January 20, 2015

Gmail: Move Email Back to Inbox

PROBLEM:  There does not seem to be a button in gmail to move an email back to inbox after removing the inbox label or archiving it.

STEPS

1.  In your browser URL, change  #inbox  to  #all

2.  Enter to refresh page

3.  "Move to Inbox" button will now show up

Wednesday, November 12, 2014

Computer Time Jargon: Unix Epoch, UTC, GMT

Computers represent TIME with many words that have similar meaning.  It creates a wall of words to climb before understanding.



UNIX Time = UNIX Epoch Time = Epoch Time = POSIX Time 

  • the number of seconds since 1/1/1970, the year Unix was born 
    • Unix computers count the time in seconds since its official "birthday," -- called "epoch" in computing terms -- which is Jan. 1, 1970.  
    • Unix engineers needed to set a uniform date for the start of computing time, and New Year's Day, 1970, the same year they started developing it, seemed most convenient.
    • Linux follows the same tradition. [Reference]
    • Years < 1970 are negative
  • Timezone it represents ALWAYS equals UTC = Universal Time = GMT [Reference]
  • More Jargon:
    • Epoch = reference point from which time is measured
    • POSIX = Portable Operating System Interface.  These are the standards that Unix and Linux were built upon.
UTC = Coordinated Universal Time = GMT = Greenwich Mean Time

  • Timezones around the world are expressed as positive or negative offsets from UTC.



REFERENCES
http://unix.stackexchange.com/questions/26205/why-does-unix-time-start-at-1970-01-01

#Wall.Of.Words #computing

Friday, October 17, 2014

Checkboxes: Check All or None on Webpage

GOAL:  Repeat checkbox multi-select similar to Google Docs and Gmail for editing multiple items in JavaScript / jQuery.

CHECK ALL
$('input:checkbox').attr('checked', true);
UNCHECK ALL
$('input:checkbox').attr('checked', false);

Thursday, September 11, 2014

"Save as Image" PNG/JPEG in Keynote [for Mac]

GOAL:  Save image in Keynote as a PNG, JPEG, PDF, or TIFF.

STEPS

1.  Copy Image in Keynote

2.  Open Preview App

3.  File > New from Clipboard

4.  Desired image should now be opened

5.  File > Save... > Choose Format > OK

Crop Image in Mac Keynote

PROBLEM:  Cannot find "Crop" or crop icon anywhere in Keynote.

STEPS

1.  Click Image

2.  Format > Image > Edit Mask

3.  Crop button now shown.  Adjust to desired size.

4.  Done

REFERENCE

Tuesday, July 15, 2014

iframe Part of a Webpage

PROBLEM
Scrape a part of a webpage onto another.

SOLUTION
iframe + disable scroll + adjust margins + set width/height

<iframe src="http://www.worldometers.info/world-population/" scrolling="no" style="height: 280px; width: 619px; margin-top: -220px; margin-left: -230px; border: 0px none;"></iframe>

Scraped Example of World Population Website

This will work as long as the webpage doesn't re-arrange content.  Debated between an iframe or jquery to scrape a certain element.  Accessing with jquery ended in permission error:
REFERENCES

Tuesday, June 24, 2014

Mac App Can't Be Opened Because Unidentified Developer [Fix]

ERROR
Can't be opened because it is from an unidentified developer (often from a newly downloaded app from the internet).  Only OK shows in the pop-up and there is no way to Open.

SOLUTION


1.  Applications folder

2.  Right Click on App

3.  Open

4.  Pop-up now shows "Open" button.  Click "Open" to use the app.


Friday, May 30, 2014

Revit Origin

GOAL: find the origin (0,0,0) of a Revit 3D Building Model

STEPS:
  1. Double Click "Level 1"
  2. "View" Tab
  3. Visibility / Graphics
  4. + Site
  5. Check "Project Base Point" & Survey Point
  6. Apply
  7. OK

Origin will now show in red.

Specific to Revit 2012.  No guarantees past this.
REFERENCES
http://danielgijsbers.blogspot.com/2012/05/revit-origin.html



Wednesday, May 28, 2014

Server Jargon: Memory vs. Storage

The memory and storage are separate pieces of hardware from the processor (described here) also on the motherboard of a computer or server.



Memory = RAM = Random Access Memory
  • Short Term Memory
  • Physically: a thin metal & plastic board

Storage = Disk Space = Hard Drive (HD) = Solid State Drive (SSD)
  • Long Term Memory
  • Physically: a small metal box



WOW.  If you're a server beginner, this is another Wall Of Words you have to climb.
DISCLAIMER
I'm not a computer engineer, just a software developer.  This is my understanding as of May 2014.

REFERENCES

Server Jargon: Processor vs. Core vs. Thread

A thread is inside of a core which is inside a processor which sits in a socket on a motherboard of a computer or server.  WOW.  If you're a server beginner, this is one of the Wall Of Words you have to climb.


Processor = CPU = Central Processing Unit
  • Physically:  a tiny metal board with circuits and nano-sized wiring that sits inside of a "socket" on the "motherboard".
    • Socket = the slot the processor sits in on the "motherboard"
    • Motherboard = PCB = Printed Circuit Board for a computer/server
      • 2014 Support:  only 2 sockets / slots are in a motherboard
  • Sized by:  
    • Clock Speed = # calculations in 1 second before degrading (measured in 1million+ cycles/second, MHz or GHz)

Core = a processor inside of a processor
  • Physically: a small black box inside the processor
  • 2014 Support:  2-4 cores can fit inside a processor

Thread = a process = 1 terminal command
  • Physically:  No, thread's don't exist physically.  This is an abstracted OperatingSystem / Software concept.  Certain software languages can only run 1 thread at a time.
  • 2014 Support:  2 threads can run inside a core



DISCLAIMER
I'm not a computer engineer, just a software developer.  This is my understanding as of May 2014.

REFERENCES

Thursday, May 22, 2014

Reduce File Size of Image

  1. pixlr.com/editor/
  2. Open image from computer > Browse for image
  3. File > Save...
  4. Format:  JPEG
  5. Adjust Quality dial & see resulting Size (KB) at bottom
    6.  OK
    7.  Choose where you want the image downloaded to


Free Online Alternative to Photoshop

Pixlr is a free, online, web app alternative to Adobe Photoshop...  pixlr.com/editor/



It can perform many of the basic functions of Photoshop such as:
  • resizing images
  • setting a transparent background
  • deleting chunks of the image with magic wand
  • converting to JPEG, PNG, BMP, TIFF
  • adjusting the color or grayscale, etc.  
It's all FREE and doesn't require any installs.



Friday, May 2, 2014

Bootstrap #id href Link Covered by Nav Bar [Fixed]

< h1 id="output" style="padding-top:40px; margin-top:-40px;">

this does not create extra space in content & href to #output now jumps down to this anchor without the top nav bar (default in twitter bootstrap) covering the title up.  no change needed for the href="#output" tag at top.

BEFORE

AFTER
REFERENCE
http://stackoverflow.com/questions/9047703/fixed-position-navbar-obscures-anchors

Thursday, May 1, 2014

OpenSSL Bug Fix for Ubuntu Linux 12.04 by Bitnami

The OpenSSL Heartbleed Bug affected the majority of the internet in early April 2013.  If you haven't patched your ubuntu server yet...

CHECK
BAD
built on: Tue Jun  4 07:26:06 UTC 2013
(or anything earlier than Apr 7 2014 is vulnerable to the OpenSSL Bug)
OpenSSL 1.0.1 14 Mar 2012 does not matter [reference], only the "built on" date.

GOOD
built on: Mon Apr  7 20:33:29 UTC 2014

FIX UBUNTU 12.04
sudo apt-get update 
sudo apt-get upgrade
(note: upgrade does not change your ubuntu version)

FIX UBUNTU 12.04 by BITNAMI
1. wget http://downloads.bitnami.com/files/download/opensslfixer/bitnami-opensslfixer-1.0.1g-1-linux-x64-installer.run 
2. chmod +x ./bitnami-opensslfixer-1.0.1g-1-linux-x64-installer.run

3. sudo ./bitnami-opensslfixer-1.0.1g-0-linux-x64-installer.run --mode text

ALTERNATIVES

REFERENCES
Bitnami creates custom builds of Ubuntu to make the setup easier for developers.  


Disk Space Tool for Ubuntu Linux Server

GOAL
Find out the breakdown of which files/folders are taking up the most room on your computer / server through command line / terminal.
INSTALL
sudo apt-get install gt5

COMMAND TO RUN
from the directory you want to analyze:
gt5

COMMAND TO EXIT
Ctrl + Z

FOR
Ubuntu Linux 12.04

REFERENCES

Forward Penn State Email to Gmail

  1. Change your email@psu.edu forwarding address (here)
  2. Sign In 
  3. Change

Friday, April 18, 2014

Shortcut Top/Bottom of Page in Chrome for MacOSX

Top of Page
FN + LEFT arrow 
or CMD + UP arrow

Bottom of Page
FN + RIGHT arrow 
or CMD + DOWN arrow

SPECIFIC TO 
Chrome Web Browser on MacBook OSX
Small Keyboard without right Number Keypad
REFERENCES

Wednesday, April 16, 2014

Google Maps Autocomplete

GOAL
As a user types in an address, Google Maps attempts to auto-complete so the user can see all locations in the world that match the entered address.  It ultimately saves the user time so they only have to enter the start of the address.

CODE
All JavaScript & HTML in one file here:
https://gist.github.com/joshwentz/10904677

DEMO
http://codepen.io/joshwentz/pen/mLyrh


IMPLEMENTATION
Live Web App:  http://node.eebhub.org
Code here

REFERENCE
https://developers.google.com/maps/documentation/javascript/examples/places-autocomplete


Thursday, April 10, 2014

Fix "Cannot find module OpenStudio" for Node.js Bindings on Ubuntu Linux

ERROR: Cannot find module 'OpenStudio'



PROBLEM: Your JavaScript cannot find where the OpenStudio software libraries are.  



SOLUTION

1. Login as user & add to $PATH
export NODE_PATH=/usr/local/lib/openstudio/node
PATH=$PATH:/usr/local/lib/openstudio/node
sudo -s 
sudo echo 'export NODE_PATH=/usr/local/lib/openstudio/node' >> /etc/profile 
sudo echo 'export PATH=$PATH:$NODE_PATH' >> /etc/profile
2. Login as root & add to $PATH
sudo -i 
sudo echo 'export NODE_PATH=/usr/local/lib/openstudio/node' >> /etc/environment
sudo echo 'export PATH=$PATH:$NODE_PATH' >> /etc/environment

TEST
echo $PATH
echo $NODE_PATH

/usr/local/lib/openstudio/node must show up

POST SPECIFIC TO : Linux Ubuntu 12.04
REFERENCE
Jason Turner, Empty Crate
http://askubuntu.com/questions/128413/setting-the-path-so-it-applies-to-all-users-including-root-sudo

FULL ERROR
module.js:340
    throw err;
          ^
Error: Cannot find module 'OpenStudio'
    at Function.Module._resolveFilename (module.js:338:15)
    at Function.Module._load (module.js:280:25)
    at Module.require (module.js:364:17)
    at require (module.js:380:17)
    at Object. (/home/ubuntu/energyplus.io-live/routes/openstudio-run.js:2:18)
    at Module._compile (module.js:456:26)
    at Object.Module._extensions..js (module.js:474:10)
    at Module.load (module.js:356:32)
    at Function.Module._load (module.js:312:12)
    at Function.Module.runMain (module.js:497:10)

Friday, March 14, 2014

Trigger Script Every Minute/Day/Week with Crontab [Linux Ubuntu]

GOAL:  Trigger a script every 15 minutes.

SOLUTION:  
Cron = job scheduler in unix-type operating systems
Crontab = Cron Table file that configures shell commands to run on some schedule

STEPS to add script

1.  Write & Save a series of linux shell/bash commands to script.sh

nano script.sh

*PATHS MUST BE ABSOLUTE, (from root, i.e. /home/user/script.sh)*
Relative Paths Will Not Work (i.e. echo "hi" > test.txt;).  Must be echo "hi" > /home/user/test.txt;

2.  Open Cron

crontab -e

2.  Select 2 for nano (easiest linux file editor)

3.  Add to bottom of file:

#min hour day month weekday command
*/1   *    *    *    *      <command>
example
#Run Script.sh Every 15 minutes
#min hour day month weekday command
*/15   *    *    *    *     /home/user/script.sh

*preceding "sh" is not needed before the script path for cron*

STEPS to check cron status/error/log

1.  Check if cron is running

sudo status cron
2.  Open the system log file (for ubuntu)

nano /etc/rsyslog.d/50-default.conf

3.  Find the line that starts with: #cron.*  Uncomment that line to be:

cron.*

4.  Save the file (Ctrl + Z)

5.  Restart rsyslog

sudo service rsyslog restart

6.  Check cron log file

cat /var/log/cron.log

Also possible to see cron jobs with grep CRON /var/log/syslog
This didn't work for me for Ubuntu 12.04, which is why I wrote this post.

Reference








Go to End of File [Linux Nano]

Control + w + v

Jumps cursor to end of open file in terminal
REFERENCE

Linux Flavor & Version

Find Linux Flavor (Redhat, Ubuntu, etc) & Version from Terminal...

cat /etc/*-release

REFERENCE

Thursday, March 13, 2014

"this" in JavaScript

"this" in JavaScript = a referral to the parent object

TEST IT:
http://www.w3schools.com/js/tryit.asp?filename=tryjs_create_object2
adding & removing "this" was the easiest way for me to understand

EXAMPLE:
function OpenStudioModel(buildingData, runmanager) {
  this.model = new openstudio.model.Model();
  this.runManager = runmanager;
};

"this" is a replacement of OpenStudioModel function
"this" is the current instance of OpenStudioModel
"this" is adding functionality to OpenStudioModel function
"this" is short hand for OpenStudioModel.model & OpenStudioModel.runManager

REFERENCES
CodeSchool Definition of "this":  this keyword will automatically refer to the new instance of the class that is being made





Find Automated Logic WebCTRL Point Data for Web Services

Automated Logic (ALC) WebCTRL = controls software for buildings


STEPS 
to find Automated Logic’s WebCTRL point data to connect to Web Services

1.  Login to WebCTRL Website IP (must be using Internet Explorer web browser)

2.  GEO (bottom left corner)

3.  Click on one of the black icons under floor

4.  Points for Web Services = Any Yellow Point.  To see information behind the yellow points:
    Alt + Left Click on a point
    Note:  Right clicking does not work (screenshot below).  Global Modify shows up but is un-clickable.   

4.  Show Advanced

5.  Copy Geographic Location & Network Location

6.  Record & Repeat for each point of interest.

PURPOSE:  To connect a building's ALC WebCTRL to Lucid's Building Operating System, which can integrate each of these points into a more flexible and engaging building data overview.  

REFERENCES
These screenshots are only possible because of: 
Payam Delgoshaei, EEB Hub Data Scientist / Controls Engineer