Skip to content

Commit

Permalink
Replace .xyz domain with .com
Browse files Browse the repository at this point in the history
  • Loading branch information
zrwaite committed Sep 4, 2023
1 parent 410eff4 commit 7fb2bae
Show file tree
Hide file tree
Showing 7 changed files with 17 additions and 16 deletions.
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

### API service to display code data as static SVGs

See more info and authorize your account [here](https://graphs.insomnizac.xyz)
See more info and authorize your account [here](https://graphs.insomnizac.com)

## `/api/wakatime/:username`:
### Pi graph that updates every hour with a cronjob pulling data from the WakaTime API
Expand All @@ -12,13 +12,13 @@ See more info and authorize your account [here](https://graphs.insomnizac.xyz)
- **`removeDefaultIgnore=true`**: stops ignoring certain default languages (JSON, YML, Text, Markdown, etc)


<a href="https://graphs.insomnizac.xyz/api/wakatime/Insomnizac" target="_blank">
<img src="https://graphs.insomnizac.xyz/api/wakatime/Insomnizac" />
<a href="https://graphs.insomnizac.com/api/wakatime/Insomnizac" target="_blank">
<img src="https://graphs.insomnizac.com/api/wakatime/Insomnizac" />
</a>

## `/api/streak/:username`:
### Static GitHub streak graph with dark mode styles

<a href="https://graphs.insomnizac.xyz/api/streak/zrwaite" target="_blank">
<img src="https://graphs.insomnizac.xyz/api/streak/zrwaite" />
<a href="https://graphs.insomnizac.com/api/streak/zrwaite" target="_blank">
<img src="https://graphs.insomnizac.com/api/streak/zrwaite" />
</a>
2 changes: 1 addition & 1 deletion api/oauth/oauth.go
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ func OAuthHandler(c *gin.Context) {
`
} else {
welcome_message = `<h1>Welcome to CodeGraphs!</h1>
<h3>You can view your graphs <a href="https://graphs.insomnizac.xyz/` + user.Username + `">here</a></h3>
<h3>You can view your graphs <a href="https://graphs.insomnizac.com/` + user.Username + `">here</a></h3>
<p>Reach out to Zac for account verification</p>
`
Expand Down
2 changes: 1 addition & 1 deletion api/wakatime/get_code_data.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ func getCodeData(user *models.User) (models.WakatimeData, error) {
return getCodeData(user)
} else if resp.StatusCode != 200 && resp.StatusCode != 201 && resp.StatusCode != 202 {
fmt.Println("Error getting data: " + time.Now().Format("2006-01-02 15:04:05"))
mail.ErrorMessage(fmt.Sprintf("Failed to get code data: \n\n\n%+v\n\n\n<img src=\"https://graphs.insomnizac.xyz/api/wakatime/pi\" />", resp))
mail.ErrorMessage(fmt.Sprintf("Failed to get code data: \n\n\n%+v\n\n\n<img src=\"https://graphs.insomnizac.com/api/wakatime/pi\" />", resp))
return data, errors.New("failed to get code data")
}
if resp.StatusCode == 202 {
Expand Down
12 changes: 6 additions & 6 deletions client/templates/pages/index.go.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,15 @@
<p>These graphs provide an abstracted layer on top of existing svg APIs</p>
<hr/>
<h3>Static Github Streak Graph</h3>
<h4><code>https://graphs.insomnizac.xyz/api/streak/:username</code></h4>
<h4>Example: <code>https://graphs.insomnizac.xyz/api/streak/zrwaite</code></h4>
<h4><code>https://graphs.insomnizac.com/api/streak/:username</code></h4>
<h4>Example: <code>https://graphs.insomnizac.com/api/streak/zrwaite</code></h4>
<a href={{ .github_streak_graph_link }}>
<img class="githubStreakGraph" src={{ .github_streak_graph_link }} alt="Github Streak Graph" />
</a>
<hr/>
<h3>Github Languages Graph</h3>
<h4><code>http://graphs.insomnizac.xyz/api/github/languages/:username?hide=css,etc</code></h4>
<h4>Example: <code>http://graphs.insomnizac.xyz/api/github/languages/zrwaite?hide=css,html</code></h4>
<h4><code>http://graphs.insomnizac.com/api/github/languages/:username?hide=css,etc</code></h4>
<h4>Example: <code>http://graphs.insomnizac.com/api/github/languages/zrwaite?hide=css,html</code></h4>
<a href={{ .github_languages_graph_link }}>
<img class="githubLanguagesGraph" src={{ .github_languages_graph_link }} alt="Github Languages Graph" />
</a>
Expand Down Expand Up @@ -50,8 +50,8 @@
</a>
</div>
{{ else }}
<h4><code>https://graphs.insomnizac.xyz/api/wakatime/:username</code></h4>
<h4>Example: <code>https://graphs.insomnizac.xyz/api/wakatime/Insomnizac</code></h4>
<h4><code>https://graphs.insomnizac.com/api/wakatime/:username</code></h4>
<h4>Example: <code>https://graphs.insomnizac.com/api/wakatime/Insomnizac</code></h4>
{{ range .public_graph_links }}
<div class="linkedImage">
<a href={{ . }}>
Expand Down
2 changes: 1 addition & 1 deletion config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ func initDirectory() {
panic(err)
}
CONFIG.Directory = filepath.Dir(ex) + "/"
CONFIG.AppURI = "https://graphs.insomnizac.xyz"
CONFIG.AppURI = "https://graphs.insomnizac.com"
if strings.Contains(ex, "var/folders") {
fmt.Println("dev mode")
CONFIG.Dev = true
Expand Down
3 changes: 2 additions & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ services:
web:
env_file: './.env'
build: .
image: 'zrwaite/codegraphs_web:5.0.1'
image: 'zrwaite/codegraphs_web:5.0.2'
network_mode: host
ports:
- '8001:8001'
2 changes: 1 addition & 1 deletion utils/mail/mail.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ func SendMessage(toEmail string, toName string, subject string, content string)
}

func ErrorMessage(content string) (success bool) {
subject := "Error on graphs.insomnizac.xyz v5.2"
subject := "Error on graphs.insomnizac.com v5.2"
return SendMessage(config.CONFIG.ContactEmail, "Zac Waite", subject, content)
}

Expand Down

0 comments on commit 7fb2bae

Please sign in to comment.