diff options
author | Christian Kandeler <christian.kandeler@qt.io> | 2017-08-07 13:54:57 +0200 |
---|---|---|
committer | Christian Kandeler <christian.kandeler@qt.io> | 2017-08-29 08:02:53 +0000 |
commit | 69a797434c2e90cda9ac0a4271edd7c79270b2fa (patch) | |
tree | 9d46ddf067a36bb6ff67227a15891ae376dead27 /doc/man | |
parent | 16fd248b6169c89bfb9e7525b5c8bd061418f0b6 (diff) |
Add a minimal man page
It contains the list of commands and a link to our online documentation.
Auto-generated via GNU's help2man from the application's help output.
[ChangeLog] Added a man page
Change-Id: Ie7101b0941f466642d7ec89a12c4e490d6d0e16f
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
Diffstat (limited to 'doc/man')
-rw-r--r-- | doc/man/man.pri | 5 | ||||
-rw-r--r-- | doc/man/man.qbs | 66 | ||||
-rw-r--r-- | doc/man/qbs.1 | 79 | ||||
-rw-r--r-- | doc/man/see-also.h2m | 11 |
4 files changed, 161 insertions, 0 deletions
diff --git a/doc/man/man.pri b/doc/man/man.pri new file mode 100644 index 000000000..2e29f9112 --- /dev/null +++ b/doc/man/man.pri @@ -0,0 +1,5 @@ +qbs_no_man_install: return() + +man.files = $$PWD/qbs.1 +man.path = $${QBS_INSTALL_PREFIX}/share/man/man1 +INSTALLS += man diff --git a/doc/man/man.qbs b/doc/man/man.qbs new file mode 100644 index 000000000..99db2b3f8 --- /dev/null +++ b/doc/man/man.qbs @@ -0,0 +1,66 @@ +import qbs +import qbs.File +import qbs.FileInfo +import qbs.Probes +import qbs.Utilities + +Product { + name: "qbs man page" + type: ["manpage"] + + Depends { name: "qbs_app"; condition: updateManPage } + Depends { name: "qbsbuildconfig" } + + property bool updateManPage: false + property string help2ManFilePath: help2ManProbe.filePath + + Group { + name: "man page" + files: ["qbs.1"] + qbs.install: qbsbuildconfig.installManPage + qbs.installDir: "share/man/man1" + } + + Group { + name: "additional sections" + files: ["see-also.h2m"] + fileTags: ["man.section"] + } + + Rule { + condition: updateManPage + multiplex: true + explicitlyDependsOn: ["application"] + inputs: ["man.section"] + Artifact { + filePath: "qbs.1" + fileTags: ["manpage"] + } + prepare: { + var help2ManExe = product.help2ManFilePath; + if (!help2ManExe) + throw "Cannot update man page: help2man not available"; + if (Utilities.versionCompare(product.qbs.version, "1.9") < 0) + throw "Cannot update man page: qbs >= 1.9 required"; + var args = [explicitlyDependsOn.application[0].filePath, "-o", output.filePath, + "--no-info", "--name=the Qbs build tool"]; + var sections = inputs ? inputs["man.section"] : []; + for (var i = 0; i < sections.length; ++i) + args.push("--include=" + sections[i].filePath); + var help2ManCmd = new Command(help2ManExe, args); + help2ManCmd.description = "creating man page"; + var copyCmd = new JavaScriptCommand(); + copyCmd.silent = true; + copyCmd.sourceCode = function() { + File.copy(output.filePath, + FileInfo.joinPaths(product.sourceDirectory, output.fileName)); + } + return [help2ManCmd, copyCmd]; + } + } + + Probes.BinaryProbe { + id: help2ManProbe + names: ["help2man"] + } +} diff --git a/doc/man/qbs.1 b/doc/man/qbs.1 new file mode 100644 index 000000000..a26ef9b50 --- /dev/null +++ b/doc/man/qbs.1 @@ -0,0 +1,79 @@ +.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.47.4. +.TH QBS "1" "August 2017" "qbs 1.10.0" "User Commands" +.SH NAME +qbs \- the Qbs build tool +.SH SYNOPSIS +.B qbs +[\fI\,command\/\fR] [\fI\,command parameters\/\fR] +.SH DESCRIPTION +Qbs 1.10.0, a cross\-platform build tool. +.SS "Built-in commands:" +.TP +build +Build (parts of) a project. This is the default command. +.TP +clean +Remove the files generated during a build. +.TP +dump\-nodes\-tree +Dumps the nodes in the build graph to stdout. +.TP +generate +Generate project files for another build tool. +.TP +help +Show general or command\-specific help. +.TP +install +Install (parts of) a project. +.TP +list\-products +Lists all products in the project, including sub\-projects. +.TP +resolve +Resolve a project without building it. +.TP +run +Run an executable generated by building a project. +.TP +shell +Open a shell with a product's environment. +.TP +status +Show the status of files in the project directory. +.TP +update\-timestamps +Mark the build as up to date. +.SS "Auxiliary commands:" +.TP +config +This tool manages qbs settings. +.TP +config\-ui +This tool displays qbs settings in a GUI. +.TP +create\-project +This tool creates a qbs project from an existing source tree. +.TP +qmltypes +This tool dumps information about the QML types supported by qbs. +.TP +setup\-android +This tool creates qbs profiles from Android SDK and NDK installations. +.TP +setup\-qt +This tool creates qbs profiles from Qt versions. +.TP +setup\-toolchains +This tool creates qbs profiles from toolchains. +.SH "SEE ALSO" +For detailed help on a command, use the +.B help +command. For instance: +.IP +qbs help build +.PP + +The full documentation for +.B qbs +is available at <http://qbs.io>. diff --git a/doc/man/see-also.h2m b/doc/man/see-also.h2m new file mode 100644 index 000000000..7de95809b --- /dev/null +++ b/doc/man/see-also.h2m @@ -0,0 +1,11 @@ +[SEE ALSO] +For detailed help on a command, use the +.B help +command. For instance: +.IP +qbs help build +.PP + +The full documentation for +.B qbs +is available at <http://qbs.io>. |