Skip to content

Instantly share code, notes, and snippets.

@pmuellr
Created August 30, 2011 22:00
Show Gist options
  • Select an option

  • Save pmuellr/1182205 to your computer and use it in GitHub Desktop.

Select an option

Save pmuellr/1182205 to your computer and use it in GitHub Desktop.
PhoneGap plugin development helper make file
#-------------------------------------------------------------------------------
# Useful while developing a plugin that lives in the phonegap-plugins Git repo.
# - create a new sample PhoneGap project to test your plugin
# - copy this file in there
# - modify PLUGIN_DIR, PLUGIN_FILES as needed
# - run "make watch" while working on your sample to update the
# phonegap-plugins files
#-------------------------------------------------------------------------------
PLUGIN_DIR = ~/Projects/phonegap-plugins/iPhone/BarcodeScanner
PLUGIN_FILES = \
PgBarcodes/Plugins/PGBarcodeScanner.h \
PgBarcodes/Plugins/PGBarcodeScanner.mm
#-------------------------------------------------------------------------------
all: help
#-------------------------------------------------------------------------------
copy:
cp $(PLUGIN_FILES) $(PLUGIN_DIR)
#-------------------------------------------------------------------------------
watch:
run-when-changed "make copy" $(PLUGIN_FILES)
#-------------------------------------------------------------------------------
help:
@echo make targets available:
@echo " help print this help"
@echo " watch run 'make build' when a file changes"
@echo " copy copy plugin files to phonegap-plugins"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment