diff --git a/cdc.d b/cdc.d index 6fb36f9..10d83aa 100755 --- a/cdc.d +++ b/cdc.d @@ -183,7 +183,7 @@ void main(string[] args) void build_tar_gz() { - if(system("tar cf dyaml.tar * && gzip -9v dyaml.tar ") != 0) + if(system("git archive HEAD | gzip -9v > dyaml.tar.gz") != 0) { writeln("Error creating a tar.gz package."); } @@ -191,12 +191,20 @@ void main(string[] args) void build_tar_xz() { - if(system("tar cf dyaml.tar * && xz -9ev dyaml.tar ") != 0) + if(system("git archive HEAD | xz -9ev > dyaml.tar.xz ") != 0) { writeln("Error creating a tar.xz package."); } } + void build_zip() + { + if(system("git archive -odyaml.zip -9 HEAD") != 0) + { + writeln("Error creating a zip package"); + } + } + void build(string[] targets ...) { foreach(target; targets) @@ -209,6 +217,7 @@ void main(string[] args) case "unittest": build_unittest(); break; case "tar.gz": build_tar_gz(); break; case "tar.xz": build_tar_xz(); break; + case "zip": build_zip(); break; case "all": build("debug", "release", "unittest"); break; default: writeln("unknown build target: ", target); @@ -244,10 +253,9 @@ void help() " Optimizations, inlining enabled.\n" " Target binary name: 'pong-release'\n" " all All of the above.\n" - " tar.gz Unix/Linux only: Create a tar.gz package\n" - " (this just archives the directory at the moment)\n" - " tar.xz Unix/Linux only: Create a tar.xz package\n" - " (this just archives the directory at the moment)\n" + " tar.gz Needs git, gzip: Create a tar.gz package.\n" + " tar.xz Needs git, xz: Create a tar.xz package.\n" + " zip Needs zip: Create a zip package.\n" "\n" "Available options:\n" " -h --help Show this help information.\n" diff --git a/doc/doctrees/environment.pickle b/doc/doctrees/environment.pickle index b13884a..dd88601 100644 Binary files a/doc/doctrees/environment.pickle and b/doc/doctrees/environment.pickle differ diff --git a/doc/doctrees/tutorials/getting_started.doctree b/doc/doctrees/tutorials/getting_started.doctree index 2de0884..f44aca3 100644 Binary files a/doc/doctrees/tutorials/getting_started.doctree and b/doc/doctrees/tutorials/getting_started.doctree differ diff --git a/doc/html/_sources/tutorials/getting_started.txt b/doc/html/_sources/tutorials/getting_started.txt index 1cf6cff..e6d45bf 100644 --- a/doc/html/_sources/tutorials/getting_started.txt +++ b/doc/html/_sources/tutorials/getting_started.txt @@ -35,8 +35,9 @@ Download the version of DMD for your operating system and install it. Download and compile D:YAML ^^^^^^^^^^^^^^^^^^^^^^^^^^^ -The newest version of D:YAML can be found `here `_. Download a source -archive, extract it, and move to the extracted directory. +The newest version of D:YAML can be found +`here `_. Download a source archive, extract +it, and move to the extracted directory. D:YAML uses a modified version of the `CDC `_ script for compilation. To compile D:YAML, you first need to build CDC. diff --git a/doc/html/tutorials/getting_started.html b/doc/html/tutorials/getting_started.html index f5e45be..26b4242 100644 --- a/doc/html/tutorials/getting_started.html +++ b/doc/html/tutorials/getting_started.html @@ -71,8 +71,9 @@ however, at the moment they are not as up to date as DMD.

Download and compile D:YAMLΒΆ

-

The newest version of D:YAML can be found here. Download a source -archive, extract it, and move to the extracted directory.

+

The newest version of D:YAML can be found +here. Download a source archive, extract +it, and move to the extracted directory.

D:YAML uses a modified version of the CDC script for compilation. To compile D:YAML, you first need to build CDC. Do this by typing the following command into the console:

diff --git a/docsrc/tutorials/getting_started.rst b/docsrc/tutorials/getting_started.rst index 1cf6cff..e6d45bf 100644 --- a/docsrc/tutorials/getting_started.rst +++ b/docsrc/tutorials/getting_started.rst @@ -35,8 +35,9 @@ Download the version of DMD for your operating system and install it. Download and compile D:YAML ^^^^^^^^^^^^^^^^^^^^^^^^^^^ -The newest version of D:YAML can be found `here `_. Download a source -archive, extract it, and move to the extracted directory. +The newest version of D:YAML can be found +`here `_. Download a source archive, extract +it, and move to the extracted directory. D:YAML uses a modified version of the `CDC `_ script for compilation. To compile D:YAML, you first need to build CDC.