Initial commit: Digital signage system for transit departures, weather, and news ticker
This commit is contained in:
24
create-gitea-repo.ps1
Normal file
24
create-gitea-repo.ps1
Normal file
@@ -0,0 +1,24 @@
|
||||
$headers = @{
|
||||
'Authorization' = 'token 9ed750a7f1480481ff96f021c8bbf49836b902f8'
|
||||
'Content-Type' = 'application/json'
|
||||
}
|
||||
|
||||
$body = @{
|
||||
name = 'SignageHTML'
|
||||
description = 'Digital signage system for displaying transit departures, weather information, and news tickers'
|
||||
private = $false
|
||||
} | ConvertTo-Json
|
||||
|
||||
try {
|
||||
$response = Invoke-RestMethod -Uri 'http://192.168.68.53:3000/api/v1/user/repos' -Method Post -Headers $headers -Body $body
|
||||
Write-Host "Repository created successfully!"
|
||||
Write-Host "Repository URL: $($response.clone_url)"
|
||||
Write-Host "SSH URL: $($response.ssh_url)"
|
||||
$response | ConvertTo-Json -Depth 10
|
||||
} catch {
|
||||
Write-Host "Error: $($_.Exception.Message)"
|
||||
if ($_.ErrorDetails.Message) {
|
||||
Write-Host "Details: $($_.ErrorDetails.Message)"
|
||||
}
|
||||
Write-Host $_.Exception
|
||||
}
|
||||
Reference in New Issue
Block a user