Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

French manpages #1330

Closed
wants to merge 4 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
80 changes: 56 additions & 24 deletions CMake/Manpage.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -2,32 +2,64 @@ find_package(A2X)

if (A2X_FOUND)
add_custom_target(man ALL)
endif()

function(add_manpage name section)
add_custom_command(
OUTPUT ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${name}.${section}
COMMAND ${A2X_COMMAND}
--no-xmllint
--doctype manpage
--format manpage
-D ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
${CMAKE_CURRENT_SOURCE_DIR}/${name}.${section}.txt
DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/${name}.${section}.txt
COMMENT Generating manpage for ${name}.${section}
)
function(add_manpage name section locale)
if (NOT A2X_FOUND)
return()
endif()

add_custom_target(man-${name}.${section}
DEPENDS
${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${name}.${section}
if (${locale} STREQUAL "en")
set(
input
${CMAKE_CURRENT_SOURCE_DIR}/man/${name}.${section}.txt
)
add_dependencies(man
man-${name}.${section}
set(
output
${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${name}.${section}
)

install(
FILES ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${name}.${section}
DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/man/man${section}
COMPONENT documentation
set(
destination
${CMAKE_INSTALL_FULL_DATAROOTDIR}/man/man${section}
)
endfunction()
endif()
else()
set(
input
${CMAKE_CURRENT_SOURCE_DIR}/man/${name}.${section}.${locale}.txt
)
set(
output
${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${name}.${section}.${locale}
)
set(
destination
${CMAKE_INSTALL_FULL_DATAROOTDIR}/man/${locale}/man${section}
)
endif()

add_custom_command(
OUTPUT ${output}
COMMAND ${A2X_COMMAND}
--no-xmllint
--doctype manpage
--format manpage
-D ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
${input}
DEPENDS ${input}
COMMENT Generating manpage for ${name}.${section}.${locale}
)

add_custom_target(man-${name}.${section}.${locale}
DEPENDS ${output}
)
add_dependencies(man
man-${name}.${section}.${locale}
)

install(
FILES ${output}
DESTINATION ${destination}
COMPONENT documentation
RENAME ${name}.${section}
)
endfunction()
18 changes: 11 additions & 7 deletions sway/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -97,10 +97,14 @@ if (CMAKE_SYSTEM_NAME STREQUAL FreeBSD)
add_config(10-freebsd security.d/10-freebsd sway/security.d)
endif (CMAKE_SYSTEM_NAME STREQUAL FreeBSD)

if (A2X_FOUND)
add_manpage(sway 1)
add_manpage(sway 5)
add_manpage(sway-input 5)
add_manpage(sway-bar 5)
add_manpage(sway-security 7)
endif()
add_manpage(sway 1 en)
add_manpage(sway 1 ja)
add_manpage(sway 1 fr)
add_manpage(sway 5 en)
add_manpage(sway 5 fr)
add_manpage(sway-input 5 en)
add_manpage(sway-input 5 fr)
add_manpage(sway-bar 5 en)
add_manpage(sway-bar 5 fr)
add_manpage(sway-security 7 en)
add_manpage(sway-security 7 fr)
2 changes: 1 addition & 1 deletion sway/sway-bar.5.txt → sway/man/sway-bar.5.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/////
vim:set ts=4 sw=4 tw=82 noet:
vim:set ts=4 sw=4 tw=82 noet ft=asciidoc:
/////
sway-bar (5)
============
Expand Down
2 changes: 1 addition & 1 deletion sway/sway-input.5.txt → sway/man/sway-input.5.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/////
vim:set ts=4 sw=4 tw=82 noet:
vim:set ts=4 sw=4 tw=82 noet ft=asciidoc:
/////
sway-input (5)
==============
Expand Down
2 changes: 1 addition & 1 deletion sway/sway-security.7.txt → sway/man/sway-security.7.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/////
vim:set ts=4 sw=4 tw=82 noet:
vim:set ts=4 sw=4 tw=82 noet ft=asciidoc:
/////
sway-security (7)
=================
Expand Down
127 changes: 127 additions & 0 deletions sway/man/sway.1.ja.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,127 @@
/////
vim:set ts=4 sw=4 tw=82 noet ft=asciidoc:
/////
:quotes.~:

sway (1)
========

名前
----
sway - SirCmpwnのWaylandのcompositor

書式
----
'sway' [options] [command]

Options
-------

*-h, --help*::
Show help message and quit.

*-c, \--config* <config>::
Specifies a config file.

*-C, \--validate*::
Check the validity of the config file, then exit.

*-d, --debug*::
Enables full logging, including debug information.

*-v, \--version*::
Show the version number and quit.

*-V, --verbose*::
Enables more verbose logging.

*--get-socketpath*::
Gets the IPC socket path and prints it, then exits.

Description
-----------

sway was created to fill the need of an i3-like window manager for Wayland. The
upstream i3 developers have no intention of porting i3 to Wayland, and projects
proposed by others ended up as vaporware. Many thanks to the i3 folks for
providing such a great piece of software, so good that your users would rather
write an entirely new window manager from scratch that behaved _exactly_ like i3
rather than switch to something else.

Launch sway directly from a tty or via your favorite Wayland-compatible login
manager.

Commands
--------

If sway is currently running, you may run _sway [command]_ to send _command_ to
the running instance of sway. The same commands you would use in the config file
are valid here (see **sway**(5)). For compatibility reasons, you may also issue
commands with **swaymsg**(1) or **i3-msg**(1) (or even with **i3**(1), probably).

Configuration
-------------

If _-c_ is not specified, sway will look in several locations for your config
file. The suggested location for your config file is ~/.config/sway/config.
~/.sway/config will also work, and the rest of the usual XDG config locations
are supported. If no sway config is found, sway will attempt to load an i3
config from all the config locations i3 supports. Sway looks for a config file in
a fallback directory as a last resort, which is /etc/sway/ by default. A standard
configuration file is installed at this location. If still nothing is found,
you will receive an error.

To write your own config, it's suggested that you copy the default config file to
the location of your choosing and start there.

For information on the config file format, see **sway**(5).

Environment
-----------

The following environment variables have an effect on sway:

*SWAY_CURSOR_THEME*::
Specifies the name of the cursor theme to use.

*SWAY_CURSOR_SIZE*::
Specifies the size of the cursor to use.

*SWAYSOCK*::
Specifies the path to the sway IPC socket.

*WLC_DRM_DEVICE*::
Specifies the device to use in DRM mode.

*WLC_SHM*::
Set 1 to force EGL clients to use shared memory.

*WLC_OUTPUTS*::
Number of fake outputs to use when running in X11 mode.

*WLC_XWAYLAND*::
Set to 0 to disable Xwayland support.

*WLC_LIBINPUT*::
Set to 1 to force libinput (even in X11 mode).

*WLC_REPEAT_DELAY*::
Configures the keyboard repeat delay.

*WLC_REPEAT_RATE*::
Configures the keyboard repeat rate.

*XKB_DEFAULT_RULES*, *XKB_DEFAULT_MODEL*, *XKB_DEFAULT_LAYOUT*, *XKB_DEFAULT_VARIANT*, *XKB_DEFAULT_OPTIONS*::
Configures the xkb keyboard settings. See xkeyboard-config(7).

Authors
-------

Maintained by Drew DeVault <[email protected]>, who is assisted by other open
source contributors. For more information about sway development, see
<https://github.com/SirCmpwn/sway>.

See Also
--------

**sway**(5) **swaymsg**(1) **swaygrab**(1) **sway-input**(5) **sway-bar**(5)
2 changes: 1 addition & 1 deletion sway/sway.1.txt → sway/man/sway.1.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/////
vim:set ts=4 sw=4 tw=82 noet:
vim:set ts=4 sw=4 tw=82 noet ft=asciidoc:
/////
:quotes.~:

Expand Down
2 changes: 1 addition & 1 deletion sway/sway.5.txt → sway/man/sway.5.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/////
vim:set ts=4 sw=4 tw=82 noet:
vim:set ts=4 sw=4 tw=82 noet ft=asciidoc:
/////
sway (5)
========
Expand Down
5 changes: 2 additions & 3 deletions swaygrab/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,5 @@ install(
COMPONENT runtime
)

if (A2X_FOUND)
add_manpage(swaygrab 1)
endif()
add_manpage(swaygrab 1 en)
add_manpage(swaygrab 1 fr)
2 changes: 1 addition & 1 deletion swaygrab/swaygrab.1.txt → swaygrab/man/swaygrab.1.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/////
vim:set ts=4 sw=4 tw=82 noet:
vim:set ts=4 sw=4 tw=82 noet ft=asciidoc:
/////
:quotes.~:

Expand Down
5 changes: 2 additions & 3 deletions swaylock/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,5 @@ install(
COMPONENT data
)

if (A2X_FOUND)
add_manpage(swaylock 1)
endif()
add_manpage(swaylock 1 en)
add_manpage(swaylock 1 fr)
Loading