summaryrefslogtreecommitdiffstats
path: root/src/docsets.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/docsets.cpp')
-rw-r--r--src/docsets.cpp11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/docsets.cpp b/src/docsets.cpp
index 52a3c33..86fe54e 100644
--- a/src/docsets.cpp
+++ b/src/docsets.cpp
@@ -62,8 +62,11 @@ void DocSets::initialize()
"DOCSET_RESOURCES=$(DOCSET_CONTENTS)/Resources\n"
"DOCSET_DOCUMENTS=$(DOCSET_RESOURCES)/Documents\n"
"DOCSET_INSTALL=~/Library/Developer/Shared/Documentation/DocSets\n"
+ "XCODE_INSTALL=$(shell xcode-select -print-path)\n"
"\n"
- "all: always\n"
+ "all: docset\n"
+ "\n"
+ "docset:\n"
"\tmkdir -p $(DOCSET_DOCUMENTS)\n"
"\tcp Nodes.xml $(DOCSET_RESOURCES)\n"
"\tcp Tokens.xml $(DOCSET_RESOURCES)\n"
@@ -74,16 +77,16 @@ void DocSets::initialize()
"\t --exclude Info.plist \\\n"
"\t --exclude Makefile -c -f - . \\\n"
"\t | (cd $(DOCSET_DOCUMENTS); tar xvf -)\n"
- "\tdocsetutil index $(DOCSET_NAME)\n"
+ "\t$(XCODE_INSTALL)/usr/bin/docsetutil index $(DOCSET_NAME)\n"
"\trm -f $(DOCSET_DOCUMENTS)/Nodes.xml\n"
"\trm -f $(DOCSET_DOCUMENTS)/Info.plist\n"
"\trm -f $(DOCSET_DOCUMENTS)/Makefile\n"
"\trm -f $(DOCSET_RESOURCES)/Nodes.xml\n"
"\trm -f $(DOCSET_RESOURCES)/Tokens.xml\n"
"\n"
- "install:\n"
+ "install: docset\n"
"\tmkdir -p $(DOCSET_INSTALL)\n"
- "\tcp -a $(DOCSET_NAME) $(DOCSET_INSTALL)\n"
+ "\tcp -R $(DOCSET_NAME) $(DOCSET_INSTALL)\n"
"\n"
"uninstall:\n"
"\trm -rf $(DOCSET_INSTALL)\n"