Skip to contents

qgis_path() returns the filepath of the 'qgis_process' command, while qgis_version() returns the QGIS version.

Usage

qgis_path(query = FALSE, quiet = TRUE)

qgis_version(query = FALSE, quiet = TRUE, full = TRUE, debug = FALSE)

Arguments

query

Use TRUE to refresh the cached value.

quiet

Use FALSE to display more information, possibly useful for debugging.

full

Logical. If FALSE, only return the "x.y.z" version string instead of the full version string that includes the name. Defaults to TRUE; ignored if debug = TRUE.

debug

Logical. If TRUE, also output the version of QGIS, the operating system and all relevant libraries, as reported by the 'qgis_process' command.

Value

A string.

See also

qgis_configure()

Other topics about reporting the QGIS state: has_qgis(), qgis_algorithms(), qgis_using_json_input()

Examples

qgis_path()
#> [1] "qgis_process"
qgis_path(quiet = FALSE)
#> Using 'qgis_process' in the system PATH.
#> >>> If you need another installed QGIS instance, run `qgis_configure()`;
#>     see `?qgis_configure` if you need to preset the path of 'qgis_process'.
#> [1] "qgis_process"
qgis_version()
#> [1] "3.36.0-Maidenhead"
qgis_version(full = FALSE)
#> [1] "3.36.0"
qgis_version(debug = TRUE)
#> [1] "3.36.0-Maidenhead"
#> 
#> Using qgisprocess 0.3.0.9000
#> 
#> Versions reported by 'qgis_process':
#> ------------------------------------
#> QGIS 3.36.0-Maidenhead 'Maidenhead' (09951dc0acf)
#> QGIS code revision 09951dc0acf
#> Qt version 5.15.3
#> Python version 3.10.12
#> GDAL/OGR version 3.4.1
#> PROJ version 8.2.1
#> EPSG Registry database version v10.041 (2021-12-03)
#> GEOS version 3.10.2-CAPI-1.16.0
#> SQLite version 3.37.2
#> OS Ubuntu 22.04.4 LTS