WorkFlow: An Inquiry Into Productivity by Timothy Bolton
description
Transcript of WorkFlow: An Inquiry Into Productivity by Timothy Bolton
WORKFLOW: AN INQUIRTY INTO PRODUCTIVITYTIMOTHY BOLTON
Workflow
• Creating Your Environment• Dealing with External Variables
Workflow: Creating Your Environment
• Git• FileZilla• cURL• XSLTProc• Bash• VPN/Dropbox
Workflow: Git
• What is Git?• Why use Git?• Get started QUICKLY
Workflow: Git• Add files to the staging area:
• Commit the change:
• Push the change
Rinse and repeat
git add -A
git commit –m “Added getRSAFromAttr()”
git push
Workflow: Git
• Ignoring files
Workflow:touch ~/.gitignore_globalecho "# Global Git Ignore File" >> ~/.gitignore_globalecho "*.mvc" >> ~/.gitignore_globalecho "*.so" >> ~/.gitignore_globalecho "*.tar" >> ~/.gitignore_global# and so on for whatever you don't want to include..echo "temp_*.*" >> ~/.gitignore_global #For any temporary filegit config --global core.excludesfile ~/.gitignore_global
Workflow: Git
• ftp.dat
touch ./.git/ftp.datecho “# For END_PATH_LOCATION, DON'T include last slash!” >> ./.git/ftp.dat echo “# END_PATH_LOCATION upload location on server” >> ./.git/ftp.datecho ‘END_PATH_LOCATION="5.00/modules/util“’
Workflow: FileZilla
• Site Manager and sitemanager.xml
Workflow: cURL
• Why cURL is important• How to use it
Workflow: cURL
• Using cURL for what we want to do is fairly straight forward:
curl –T text.mv ftp://example.com/ --user username:password
Workflow: XSLTProc
• xsltproc• ANOTHER tool? 0___O
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
<xsl:param name="site_name">DEFAULT_SITE_HERE</xsl:param>
<xsl:param name="file_name"></xsl:param>
<xsl:param name="end_path_location"></xsl:param>
<xsl:output method="text"/>
<xsl:template match="Servers">
<xsl:for-each select="//Server">
<xsl:if test="Name=$site_name">
<xsl:choose>
<xsl:when test="Comments !=''">
<xsl:value-of select="Comments"/>
curl -T <xsl:value-of select="$file_name" /> ftp://<xsl:value-of select="Host"/>/<xsl:value-of select="Comments"/>/<xsl:value-of select="$end_path_location" />/ --user <xsl:value-of select="User"/>:<xsl:value-of select="Pass"/>
</xsl:when>
<xsl:otherwise>
curl -T <xsl:value-of select="$file_name" /> ftp://<xsl:value-of select="Host"/>/httpdocs/mm5/<xsl:value-of select="$end_path_location" />/ --user <xsl:value-of select="User"/>:<xsl:value-of select="Pass"/>
</xsl:otherwise>
</xsl:choose>
</xsl:if>
</xsl:for-each>
</xsl:template>
</xsl:stylesheet>
Workflow: Bash
• Incredibly basic scripting for the CLI• Usage of our upload.sh script
Workflow:#!/bin/sh# $1 - File Name# $2 - Site Name (As you've named it in your SiteManager)# $END_PATH_LOCATION - The location of the upload# Look into possibly getting the cwd, and uploading to that from a 'base'. .git/ftp.datXSLT_LOCATION="/d/PCINET/scripts/xml/select_server.xsl" SITE_MANAGER_LOCATION="/C/Users/Tim/AppData/Roaming/FileZilla/sitemanager.xml"if [ $# == 1 ] ; then xsltproc --stringparam file_name "$1" --stringparam end_path_location "$END_PATH_LOCATION" $XSLT_LOCATION $SITE_MANAGER_LOCATION | shelif [ $# == 2 ] ; then xsltproc --stringparam file_name "$1" --stringparam site_name "$2" --stringparam end_path_location "$END_PATH_LOCATION" $XSLT_LOCATION $SITE_MANAGER_LOCATION | shelse echo "Usage (1) is: upload.sh FILE_NAME SITE_NAME" echo "Usage (2) is: upload.sh FILE_NAME (this will upload to the default directory)" exit 1fi
Workflow: Bash
• upload.sh FILE_NAME “SITE_NAME”– (as it is named in your Site Manager)
• upload.sh FILE_NAME– (this uploads to the default directory supplied)
Workflow: Dropbox/NAS
• Centralizing file locations
Workflow: External Variables
• SNERPKWNIAAE • Phone calls• Emergencies
Workflow: SNERPKWNIAAE
• You might get this a couple of hours a day, depending on how you take control of your day.
Workflow: Phone calls
• Interruption Protocol• Dealing with interruptions• Wanted interruptions
Workflow: Emergencies
• Putting out fires• Taking responsibility
Workflow:
Workflow:
Workflow:
Workflow:
Workflow:
Workflow:
Workflow:
Workflow:
Workflow:
Workflow:
Workflow:
Workflow:
Workflow: