diff --git a/Makefile b/Makefile index 272bc43..6cef329 100644 --- a/Makefile +++ b/Makefile @@ -17,9 +17,11 @@ rpms: rpms-vm rpms-vm: rpmbuild --define "_rpmdir $(RPMS_DIR)" -bb rpm_spec/core-vm.spec + rpmbuild --define "_rpmdir $(RPMS_DIR)" -bb rpm_spec/core-vm-doc.spec rpmbuild --define "_rpmdir $(RPMS_DIR)" -bb rpm_spec/core-vm-kernel-placeholder.spec rpm --addsign \ $(RPMS_DIR)/x86_64/qubes-core-vm-*$(VERSION)*.rpm \ + $(RPMS_DIR)/x86_64/qubes-core-vm-doc-*$(VERSION)*.rpm \ $(RPMS_DIR)/x86_64/qubes-core-vm-kernel-placeholder-*.rpm rpms-dom0: diff --git a/doc/.gitignore b/doc/.gitignore new file mode 100644 index 0000000..10d00b5 --- /dev/null +++ b/doc/.gitignore @@ -0,0 +1 @@ +*.gz diff --git a/doc/Makefile b/doc/Makefile new file mode 100644 index 0000000..3ba1a48 --- /dev/null +++ b/doc/Makefile @@ -0,0 +1,29 @@ +VM_DIR=vm-tools +PANDOC=pandoc -s -f rst -t man +RPMS_DIR=rpm/ + +VM_DOCS=$(patsubst %.rst,%.1.gz,$(wildcard $(VM_DIR)/*.rst)) + +help: + @echo "make rpms -- generate manpages and create RPM package" + @echo "make rst=example.rst preview -- generate manpage preview from example.rst" + @echo "make manpages -- generate manpages" + @echo "make install -- generate VM manpages and copy them to /usr/share/man" + +install: manpages + mkdir -p $(DESTDIR)/usr/share/man/man1 + cp $(VM_DOCS) $(DESTDIR)/usr/share/man/man1/ + +%.1: %.rst + $(PANDOC) $< > $@ + +%.1.gz: %.1 + gzip -f $< + +manpages: $(QVM_DOCS) $(QUBES_DOCS) $(VM_DOCS) + +preview: $(rst) + pandoc -s -f rst -t man $(rst) | groff -mandoc -Tlatin1 | less -R + +clean: + rm -f $(VM_DOCS) diff --git a/doc/vm-tools/qvm-copy-to-vm.rst b/doc/vm-tools/qvm-copy-to-vm.rst new file mode 100644 index 0000000..3ba912d --- /dev/null +++ b/doc/vm-tools/qvm-copy-to-vm.rst @@ -0,0 +1,24 @@ +============== +qvm-copy-to-vm +============== + +NAME +==== +qvm-copy-to-vm - copy specified files to specified destination VM + +:Date: 2012-05-30 + +SYNOPSIS +======== +| qvm-copy-to-vm [--without-progress] dest_vmname file [file]+ + +OPTIONS +======= +--without-progress + Don't display progress info + +AUTHORS +======= +| Joanna Rutkowska +| Rafal Wojtczuk +| Marek Marczykowski diff --git a/doc/vm-tools/qvm-open-in-dvm.rst b/doc/vm-tools/qvm-open-in-dvm.rst new file mode 100644 index 0000000..557276e --- /dev/null +++ b/doc/vm-tools/qvm-open-in-dvm.rst @@ -0,0 +1,22 @@ +=============== +qvm-open-in-dvm +=============== + +NAME +==== +qvm-open-in-dvm - open a specified file in disposable VM + +:Date: 2012-05-30 + +SYNOPSIS +======== +| qvm-open-in-dvm filename + +OPTIONS +======= + +AUTHORS +======= +| Joanna Rutkowska +| Rafal Wojtczuk +| Marek Marczykowski diff --git a/doc/vm-tools/qvm-open-in-vm.rst b/doc/vm-tools/qvm-open-in-vm.rst new file mode 100644 index 0000000..a7f2703 --- /dev/null +++ b/doc/vm-tools/qvm-open-in-vm.rst @@ -0,0 +1,22 @@ +============== +qvm-open-in-vm +============== + +NAME +==== +qvm-open-in-vm - open a specified file in other VM + +:Date: 2012-05-30 + +SYNOPSIS +======== +| qvm-open-in-vm vmname filename + +OPTIONS +======= + +AUTHORS +======= +| Joanna Rutkowska +| Rafal Wojtczuk +| Marek Marczykowski diff --git a/doc/vm-tools/qvm-run.rst b/doc/vm-tools/qvm-run.rst new file mode 100644 index 0000000..c496c08 --- /dev/null +++ b/doc/vm-tools/qvm-run.rst @@ -0,0 +1,22 @@ +======= +qvm-run +======= + +NAME +==== +qvm-run - run a specified command in a specified VM + +:Date: 2012-05-30 + +SYNOPSIS +======== +| qvm-run vmname command [aguments] + +OPTIONS +======= + +AUTHORS +======= +| Joanna Rutkowska +| Rafal Wojtczuk +| Marek Marczykowski diff --git a/rpm_spec/core-vm-doc.spec b/rpm_spec/core-vm-doc.spec new file mode 100644 index 0000000..352fe77 --- /dev/null +++ b/rpm_spec/core-vm-doc.spec @@ -0,0 +1,57 @@ +# +# The Qubes OS Project, http://www.qubes-os.org +# +# Copyright (C) 2010 Joanna Rutkowska +# Copyright (C) 2010 Rafal Wojtczuk +# Copyright (C) 2012 Marek Marczykowski +# +# This program is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License +# as published by the Free Software Foundation; either version 2 +# of the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. +# +# + +%{!?version: %define version %(cat version)} + + +Name: qubes-core-vm-doc +Version: %{version} +Release: 1 +Summary: The Qubes docs for VM tools + +Group: Qubes +Vendor: Invisible Things Lab +License: GPL +URL: http://www.qubes-os.org +BuildRequires: pandoc +BuildArch: noarch +Obsoletes: qubes-doc-vm <= 2.0 + +%define _builddir %(pwd)/doc + +%description +The Qubes docs for VM tools + +%build +make manpages + +%install + +make DESTDIR=$RPM_BUILD_ROOT install + +%clean +rm -rf $RPM_BUILD_ROOT + +%files +%defattr(-,root,root,-) +%{_mandir}/man1/qvm-*.1*