{"id":17648777,"url":"https://github.com/zntfdr/selenops","last_synced_at":"2025-05-08T21:25:43.947Z","repository":{"id":63921272,"uuid":"87183107","full_name":"zntfdr/Selenops","owner":"zntfdr","description":"A Swift Web Crawler 🕷","archived":false,"fork":false,"pushed_at":"2021-01-17T15:15:58.000Z","size":532,"stargazers_count":253,"open_issues_count":0,"forks_count":18,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-02-02T03:54:15.944Z","etag":null,"topics":["command-line-tool","crawler","scripting","swift","web"],"latest_commit_sha":null,"homepage":"","language":"Swift","has_issues":false,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/zntfdr.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-04-04T12:20:43.000Z","updated_at":"2024-11-01T23:11:35.000Z","dependencies_parsed_at":"2023-01-14T14:15:33.230Z","dependency_job_id":null,"html_url":"https://github.com/zntfdr/Selenops","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zntfdr%2FSelenops","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zntfdr%2FSelenops/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zntfdr%2FSelenops/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zntfdr%2FSelenops/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/zntfdr","download_url":"https://codeload.github.com/zntfdr/Selenops/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":238044095,"owners_count":19407128,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["command-line-tool","crawler","scripting","swift","web"],"created_at":"2024-10-23T11:20:34.804Z","updated_at":"2025-02-10T02:09:53.473Z","avatar_url":"https://github.com/zntfdr.png","language":"Swift","readme":"# Selenops\n\u003cp align=\"center\"\u003e\n    \u003cimg src=\"logo.png\" width=\"580\" max-width=\"90%\" alt=\"Selenops logo\" /\u003e\n    \u003cbr/\u003e\n    \u003cimg src=\"https://img.shields.io/badge/swift-5.1-orange.svg\" /\u003e\n    \u003ca href=\"https://swift.org/package-manager\"\u003e\n        \u003cimg src=\"https://img.shields.io/badge/swiftpm-compatible-brightgreen.svg?style=flat\" alt=\"Swift Package Manager\" /\u003e\n    \u003c/a\u003e\n     \u003cimg src=\"https://img.shields.io/badge/platforms-macOS+iOS+iPadOS+tvOS+watchOS-brightgreen.svg?style=flat\" alt=\"MacOS + iOS + iPadOS + tvOS + watchOS\"/\u003e\n    \u003ca href=\"https://twitter.com/zntfdr\"\u003e\n        \u003cimg src=\"https://img.shields.io/badge/twitter-@zntfdr-blue.svg?style=flat\" alt=\"Twitter: @zntfdr\" /\u003e\n    \u003c/a\u003e\n\u003c/p\u003e\n\nWelcome to **Selenops**, a Swift Web Crawler.\n\nGiven a webpage url and a word to search, Selenops will look for said word in that page, and all pages linked in there, recursively.\n\n## Usage\n\n```swift\nimport Selenops\n\n// Initialize crawler.\nlet crawler = Crawler(\n  startURL: URL(string: \"https://fivestars.blog/\")!,\n  maximumPagesToVisit: 10,\n  wordToSearch: \"Swift\" // Specify the word to search here.\n)\n\n// Set delegate.\ncrawler.delegate = ... // Needs to conform to CrawlerDelegate\n\n// Start crawling!\ncrawler.start()\n```\n\nThe `crawler` delegate will get information such as visited webpages, and in which webpages the specified word has been found.\n\n## Installation\n\nSelenops is distributed via the [Swift Package Manager](https://swift.org/package-manager):  \n\n- to use it into an app, follow [this tutorial](https://developer.apple.com/documentation/swift_packages/adding_package_dependencies_to_your_app) and use this repository URL: `https://github.com/zntfdr/Selenops.git`.\n\n- to use it in a package, add it as a dependency in your `Package.swift`:\n```swift\n let package = Package(\n     ...\n     dependencies: [\n         .package(url: \"https://github.com/zntfdr/Selenops.git\", from: \"2.0.0\")\n     ],\n     targets: [\n        .target(\n            ...\n            dependencies: [\"Selenops\"])\n     ],\n     ...\n )\n```\n  ...and then use `import Selenops` whenever necessary.\n\n## Command line tool\n\u003cp align=\"center\"\u003e\n    \u003cimg src=\"cli-example.gif\" max-width=\"90%\" alt=\"Swift Web Crawler in action\" /\u003e\n\nSelenops also comes with a command line tool that showcases its functionality.\n\nTo install it, clone the project and run make:\n\n```shell\n$ git clone https://github.com/zntfdr/Selenops.git\n$ cd Selenops\n$ make\n```\n\n## Credits\n\nSelenops was built by [Federico Zanetello](https://twitter.com/zntfdr) as an [example of a Swift script][selenopsArticle].\n\n## Contributions and Support\n\nAll users are welcome and encouraged to become active participants in the project continued development — by fixing any bug that they encounter, or by improving the documentation wherever it’s found to be lacking.\n\nIf you'd like to make a change, please [open a Pull Request](https://github.com/zntfdr/Selenops/pull/new), even if it just contains a draft of the changes you’re planning, or a test that reproduces an issue.\n\nThank you and please enjoy using **Selenops**!\n\n[selenopsArticle]: https://www.fivestars.blog/code/build-web-crawler-swift.html\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzntfdr%2Fselenops","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fzntfdr%2Fselenops","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzntfdr%2Fselenops/lists"}