OBS QML Type

Interface to OpenSuSE Commander, a.k.a. osc More...

Import Statement: import org.nephros.sailfish.OBSMaster 1.0

Properties

Signals

Methods

Detailed Description

Singleton. Wraps a Python object (via io.thp.pyotherside) which presents an interface to the osc tool (as well as some additional/helper functions).

Property Documentation

apiurl : string

The API URL for the configured OBS instance. Used e.g. to open stuff in the Browser.


busy : bool

true when we're doing something, i.e. an asynchronous process has been started and we are awaiting a callback.


cmdError : string

Stores the standard error stream of the last command executed by the osc Python helper.


currentPackage : OBSProject

Holds the meta data representing a (usually local) Package or Project.


currentProject : OBSProject

Holds the meta data representing a (usually local) Package or Project.


filteredPrjList : FilterModel

Holds the list of all known projects (upstream), without user homes.

See also getProjectList and projectList.


hasToken : bool

true when there is a valid auth token for the current OBS instance.


initialized : bool

true when the OBSMaster.OBS Singleton has reached a usable state.

Warning: No method calls to this type shall be made before this property has changed to true.


lastError : string

Store the last activity status or an error message received by the osc Python helper

See also cmdError.


lastStatus : string

Store the last activity status or an error message received by the osc Python helper

See also cmdError.


projectList : ListModel

Holds the list of all known projects (upstream).

See also getProjectList.


user : string

The name of the last authenticated/configured user.


userMeta : var

user meta data, as an object:

 {
   "person": {
     "login": "testuser",
     "email": "test@example.org",
     "realname": "-- --",
     "state": "confirmed",
     "watchlist": null
   }
 }

workerStatusXml : string

Holds the build worker statistics

See also getWorkerStatus().


Signal Documentation

chumFound(string path)

Emitted when the current working dir looks like a Chum working dir. Used in the app to store the path to persistent storage.


chumTestingFound(string path)

Emitted when the current working dir looks like a Chum:Testing working dir. Used in the App to store the path to persistent storage.


downloadFinished()

Emitted when a download has finished. This could be a binary download, or an update or checkout command completing.


error(string message)

Emitted when the API interface reports an error (or anything else written to stderr). message is the content of stderr.

See also cmdError.


finished()

Emitted when a background process has finished.


metaReceived(string meta)

Emitted when a meta data set has been downloaded. meta are its contents.


packageCreated()

Emitted when the mkpac() method finishes.

See also mkpac().


projectCreated()


remoteFilesXmlChanged()

Emitted when the remote files list changed

See also OBSPackage::remoteFilesXml.


remoteRunning()

Emitted when the a remote run has been triggered.

See also remoteRun().


resultXmlChanged(string which)

Emitted when the result list changed,

which can be one of:

ConstantDescription
project 
packagewhich is the content type received.

See also OBSTypeBase::resultXml.


rpmLintLogReceived(string data)

Emitted when an rpmlint log file has been received.


uploadFinished()

Emitted when an upload has finished.


Method Documentation

abortBuild(pr, pk, repo, arch)

Aborts a build of the package pk, repo, and arch corresponding to the arguments


addFiles(files)


checkIn()


checkLogin()

Retrieve an auth token from the server.

Used to check that authorization is set up correctly.

See also SettingsPage.


checkOut(name, limit)

Check out package name, optionally applying a size limit limit


checkOutProject(name, destination, limit)

Check out project name into path destination, optionally applying a size limit limit


createRemoteProject(pname, parentprj, dobuild, dodebug, dopublish, doufb, extradata)


getBinaries(repo, arch)

Retrieves build results (binaries) from repo repo and for arch arch


getBuildInfoDetails(pr, pk, repo, arch)

Synchronously retrieves build result detail information, returns an JSON String


getBuildLogUrl(pr, pk, repo, arch)

Returns the public(!) URL (!) of a build log corresponding to the arguments


getBuildResultInfo(pr, pk, repo, arch, name, extended)

Synchronously loads the build result detail information, returns a JSON String


getBuildResultList(pr, pk, repo, arch)

Synchronously loads the build result list. Returns and array of objects

Note: pre-0.6, this used to return XML

This QML method was introduced in Qt 0.6.


getConfig(section, value)

Retrieve the local configuration values. If parameters section and value are specified, return the value of the relevant setting.

See also SettingsPage.


getDirFileStatus()

Calls osc status on the current working directory

See also getFileStatus.


getFileStatus(file)

Calls osc status on a single file

See also getDirFileStatus.


getLocalPkgList(path)

Reads the list of local packages for a project directory path, and assigns them to a the localPackagesList property of currentProject.

See also OBSProject::localPackagesList.


getMetaXml(which, prj, pkg)

Gets the meta information of type which for prj, pkg by API call. Emits metaReceived() when done.


getPrjConfMeta(name)

Gets the meta information for name by API call.

Emits metaReceived() when done.


getProjectList(root, refresh)

Retrieves the list of projects from the server.

root - an optional project name to start from refresh - force loading even if already have a list

Updates projectList and filteredPrjList with the information received.


getRPMLintLog(proj, pkg, repo, arch)

Retrieves an rpmlint log file, using the native osc python interface.

Emits rpmLintLogReceived() when finished.


getRemoteFilesInfo(pr, pk, expand)

Retrieves the list of source files results by calling the OBS API. If expand is true, the any links are expanded.


getResults(pr, pk, repo, arch)

Retrieves the list of build results by calling the OBS API. pr is mandatory, pk, repo and arch optional parameters to the call.


getServiceInfo()

Reads the meta data from a local _service file.


getWDInfo(dir)

Given a local directory dir, tries to determine whether it is a package or project dir, sets up the corresponding types. path will be used to trigger initialization of those types.

Note: this will destroy() current instances of OBSProject and OBSPackage and create new ones.

See also currentProject, currentPackage, newProject(), and newPackage().


getWorkerStatus()

Fetches some statistics for the build workers from the OBS API path /worker/_status.

See also api.


metaFromSpec()


mkpac(name)

Creates a new local package under currentProject.path Emits OBS::packageCreated when done


newPackage(parentobj, properties)

Creates a new OBSPackage object via createObject(). The parentobj, and properties parameters correspond to the parameters of that call.

See also QtQml::Component.createObject().


newProject(parentobj, properties)

Creates a new OBSProject object via createObject(). The parentobj, and properties parameters correspond to the parameters of that call.

See also QtQml::Component.createObject().


openShell()

Launches an external Terminal application and shell in the current working directory.


putFile()


putMeta(which, filepath, projectName, packageName)

Upload a meta file filename of type which. projectName is the project name packageName the package name. The latter is required if which is "pkg", and is ignored otherwise.

Emits uploadFinished() on success.


rebuild(prj, pk, repo, arch, opt)

Triggers a rebuild of either all packages of the current project, or the current package, or just for failed packages.


rebuildAll()


rebuildFailed()


rebuildPackage(pr, pk, repo, arch)


remoteRun()

Triggers a remote service run for the current Package. Emits remoteRunning()


runSpectacle(fileurl)


saveTmpXMLFile(payload, callback)


setPkgInfoFromPath(dir)

Investigates dir, and assigns the various metadata as appropriate.

See also OBSPackage.


setPrjInfoFromPath(dir)

Investigates dir, and assigns the various metadata as appropriate.

See also OBSProject.


updateWD(what)

Calls update on the current path. what specifies whether we want to update a project or package dir.

Emits downloadFinished() when done.


xmlToJSON(xml)

Converts xml to a JSON string(!)



OBS Master Documentation Copyright (c) 2023 The OBS Master contributors. This document may be used under the terms of the Creative Commons Attribution Share Alike 4.0 International License.