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 toTRUE
; ignored ifdebug = 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.
See also
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.38.3-Grenoble"
qgis_version(full = FALSE)
#> [1] "3.38.3"
qgis_version(debug = TRUE)
#> [1] "3.38.3-Grenoble"
#>
#> Using qgisprocess 0.4.1.9000
#>
#> Versions reported by 'qgis_process':
#> ------------------------------------
#> QGIS 3.38.3-Grenoble 'Grenoble' (37f9e6efeec)
#> QGIS code revision 37f9e6efeec
#> 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.5 LTS