Sunday, August 5, 2012

One-keyboard-button compile your Google Drive-hosted Latex project

Context

First off, you already have your report on Google Drive and have made a compile-script, right? (See earlier post of how to set that up). 

Binding F2 to run the script

Let's say that "C:\thesis\build.bat" is the script that will download and compile your report. If we can bind one keyboard button to run that script (regardless of currently focused application) it could speed things up.

Here's how to beat Windows into running a .bat file by a key-press:

  1. Right-click on "Cmd" in the start-menu and "Send to taskbar" (making a shortcut among the Windows 7 speed-launch-icons)
  2. Shift-right-click the new cmd-icon in the taskbar and press Properties
  3. In "target" box append: /C "C:\thesis\build.bat"
    It should now say %windir%\system32\cmd.exe /C "C:\thesis\\build.bat" in the target-box. 
  4. In the keyboard-shortcut field select with mouse and press (for example) F2.
  5. [Ok]
Now pressing F2 at any time brings up a console windows with your build-script flashing by like a black-and-white Matrix scene, and the disappears. This is great for typing in the Google Drive document and having your pdf open on the other monitor in SumatraPDF which auto-refreshes the PDF when the file is updated.

2 comments:

  1. Can you eat 'eat 'chilly' on a zombie ate?
    Here starvegad is fun88 vin one of the best videos of zombie ate - an incredible zombie ate. 'Sully ate the whole meal' and ate the whole.

    ReplyDelete
  2. How to Play Casino: Easy Guide to playing slots on
    Casino games are played by air jordan 18 retro men blue great site 4 players, the average time they take turns is air jordan 18 retro yellow suede free shipping around 14:20. The house new air jordan 18 retro yellow is replica air jordan 18 retro red divided into three distinct categories: the 하랑 도메인 house

    ReplyDelete