feat: add support for gitea session tokens
This commit is contained in:
@@ -4,6 +4,12 @@ import Foundation
|
||||
let gitea = URL(string: "https://git.kpgpmc.org/explore/repos")!
|
||||
var request = URLRequest(url: gitea)
|
||||
request.httpMethod = "GET"
|
||||
|
||||
if CommandLine.arguments.count > 1,
|
||||
let cookiestring = String?(CommandLine.arguments[1]) {
|
||||
request.setValue("i_like_gitea=\(cookiestring)", forHTTPHeaderField: "Cookie")
|
||||
}
|
||||
|
||||
let semaphore = DispatchSemaphore(value: 0)
|
||||
let search_string = "tw-text-primary name"
|
||||
let hrefRegex = #/href="([^"]+)"/#
|
||||
|
||||
Reference in New Issue
Block a user