Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/astzweig/swift-about-app
A library to retrieve information about the swift application during runtime.
https://github.com/astzweig/swift-about-app
bundle information swift version
Last synced: about 2 months ago
JSON representation
A library to retrieve information about the swift application during runtime.
- Host: GitHub
- URL: https://github.com/astzweig/swift-about-app
- Owner: astzweig
- License: eupl-1.2
- Created: 2024-07-15T23:41:19.000Z (6 months ago)
- Default Branch: main
- Last Pushed: 2024-07-15T23:55:04.000Z (6 months ago)
- Last Synced: 2024-07-16T03:26:14.366Z (6 months ago)
- Topics: bundle, information, swift, version
- Language: Swift
- Homepage:
- Size: 11.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# AboutApp
AboutApp is a library to retrieve information about the application during
runtime, e.g. the app name or the app version.## Usage
Use AboutApp:```swift
import AboutApp@main
struct YourApp {
public static func main() {
let appName = AboutApp.shared.appName
print("Application name is \(appName)")
}
}
```## Documentation
The library has enriched symbol documentation for [DocC].[DocC]: https://www.swift.org/documentation/docc/documenting-a-swift-framework-or-package
## Changelog
This project keeps a [changelog](CHANGELOG.md) that adheres to
[Keep a Changelog](https://keepachangelog.com/en/1.1.0/).## Testing `AboutApp`
AboutApp includes a test target that can be run by```sh
$ swift test
```in the package folder or perform the Test action in Xcode (⌃⌥⌘U).
## Adding AboutApp as a Dependency
To use the AboutApp library in a project, add it to the dependencies of the
package:```swift
let package = Package(
// name, platforms, products, etc.
dependencies: [
// other dependencies
.package(url: "https://github.com/astzweig/swift-about-app", from: "0.1.0"),
],
targets: [
.executableTarget(name: "", dependencies: [
// other dependencies
.product(name: "AboutApp", package: "swift-about-app"),
]),
// other targets
]
)
```### Supported Versions
The minimum Swift version supported by swift-about-app releases are detailed below:
swift-about-app | Minimum Swift Version
---------------------------|----------------------
`0.0.1 ...` | 5.7