Skip to content

Commit

Permalink
Refactor main.go, add issue templates, add TODO list
Browse files Browse the repository at this point in the history
  • Loading branch information
Vic Shóstak committed Dec 29, 2019
1 parent 639c291 commit 05f77fa
Show file tree
Hide file tree
Showing 8 changed files with 129 additions and 34 deletions.
31 changes: 31 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
---
name: Bug report
about: Create a report to help us improve
title: ""
labels: ""
assignees: ""
---

**Describe the bug**
A clear and concise description of what the bug is.

**To Reproduce**
Steps to reproduce the behavior:

1. Go to '...'
2. Click on '....'
3. See error

**Expected behavior**
A clear and concise description of what you expected to happen.

**Screenshots**
If applicable, add screenshots to help explain your problem.

**Desktop (please complete the following information):**

- OS: [e.g. macOS]
- Version [e.g. 10.14.6]

**Additional context**
Add any other context about the problem here.
19 changes: 19 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
---
name: Feature request
about: Suggest an idea for this project
title: ""
labels: ""
assignees: ""
---

**Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

**Describe the solution you'd like**
A clear and concise description of what you want to happen.

**Describe alternatives you've considered**
A clear and concise description of any alternative solutions or features you've considered.

**Additional context**
Add any other context or screenshots about the feature request here.
14 changes: 14 additions & 0 deletions .github/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# Configuration for new-issue-welcome - https://github.com/behaviorbot/new-issue-welcome
# Comment to be posted to on first time issues
newIssueWelcomeComment: >
Thanks for opening your first issue here! 🎉 Be sure to follow the issue template!
# Configuration for new-pr-welcome - https://github.com/behaviorbot/new-pr-welcome
# Comment to be posted to on PRs from first time contributors in your repository
newPRWelcomeComment: >
Thanks for opening this pull request! 🎉 Please check out our contributing guidelines.
# Configuration for first-pr-merge - https://github.com/behaviorbot/first-pr-merge
# Comment to be posted to on pull requests merged by a first time user
firstPRMergeComment: >
Congrats on merging your first pull request! 🎉 We here at behaviorbot are proud of you!
26 changes: 26 additions & 0 deletions .github/stale.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# Number of days of inactivity before an issue becomes stale
daysUntilStale: 60

# Number of days of inactivity before a stale issue is closed
daysUntilClose: 7

# Issues with these labels will never be considered stale
exemptLabels:
- pinned
- security

# Label to use when marking an issue as stale
staleLabel: wontfix

# Comment to post when marking an issue as stale. Set to `false` to disable
markComment: >
👋 Hello. Is this still relevant? If so, what is blocking it? Is there
anything you can do to help move it forward?
> This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.
Thank you for your contributions.
# Comment to post when closing a stale Issue or Pull Request. Set to `false` to disable
closeComment: >
⚡️ This issue has been automatically closed because it has not had recent activity.
39 changes: 23 additions & 16 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ Therefore, I was very upset that _Yandex.Music_ does not have a macOS (or Window

## 🔗 [Download](https://github.com/koddr/yandex-music-desktop/releases) latest version:

- [Apple macOS 10.11+ x64](https://github.com/koddr/yandex-music-desktop/releases/download/0.2.2/yamusic_desktop-macosx-amd64.dmg) (`.dmg`, 2.39 MB)
- [Microsoft Windows 10 x64](https://github.com/koddr/yandex-music-desktop/releases/download/0.2.2/yamusic_desktop-windows-10-amd64.zip) (`.zip`, 2.11 MB)
- [Apple macOS 10.11+ x64](https://github.com/koddr/yandex-music-desktop/releases/download/0.2.3/yamusic_desktop-macosx-amd64.dmg) (`.dmg`, 2.39 MB)
- [Microsoft Windows 10 x64](https://github.com/koddr/yandex-music-desktop/releases/download/0.2.3/yamusic_desktop-windows-10-amd64.zip) (`.zip`, 2.11 MB)

GNU/Linux → coming as soon as possible.

Expand All @@ -44,21 +44,22 @@ package main
import "github.com/zserge/webview"

func main() {
// Webview options:
// - name: Yandex.Music Desktop
name := "Yandex.Music Desktop"
// - URL to login screen: https://passport.yandex.com/auth?...
url := "https://passport.yandex.com/auth?origin=music_button-header&retpath=https%3A%2F%2Fmusic.yandex.com%2Fhome"
// - sizes: 800x800 px
width := 800
height := 800
// - resizable: true
resizable := true

// Let's open window app with options:
webview.Open(name, url, width, height, resizable)
// URL params
p := "origin=music_button-header&retpath=https%3A%2F%2Fmusic.yandex.com%2Fhome"

// Init app with webview options
w := webview.New(webview.Settings{
Title: "Yandex.Music Desktop",
URL: "https://passport.yandex.com/auth?" + p,
Width: 800,
Height: 960,
Resizable: true,
Debug: false, // set to true, if you want to show web inspector
})

// Run app
w.Run()
}

```

</details>
Expand Down Expand Up @@ -168,6 +169,12 @@ If you want to say «thank you» or/and support active development `Yandex.Music

Thanks for your support! 😘 Together, we make this project better every day.

## TODO

- Add GNU/Linux (amd64) version
- Add icon for Windows 10 version
- Fix low quality rendering Cocoa/WebKit on macOS

## License

_Yandex.Music Desktop_ by [Vic Shóstak](https://github.com/koddr) is an open source software under [MIT](LICENSE) license.
Expand Down
5 changes: 1 addition & 4 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,4 @@ module github.com/koddr/yandex-music-desktop

go 1.13

require (
github.com/karalabe/xgo v0.0.0-20191115072854-c5ccff8648a7 // indirect
github.com/zserge/webview v0.0.0-20191103184548-1a9ebffc2601
)
require github.com/zserge/webview v0.0.0-20191103184548-1a9ebffc2601
3 changes: 1 addition & 2 deletions go.sum
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
github.com/karalabe/xgo v0.0.0-20191115072854-c5ccff8648a7 h1:AYzjK/SHz6m6mg5iuFwkrAhCc14jvCpW9d6frC9iDPE=
github.com/karalabe/xgo v0.0.0-20191115072854-c5ccff8648a7/go.mod h1:iYGcTYIPUvEWhFo6aKUuLchs+AV4ssYdyuBbQJZGcBk=
github.com/akavel/rsrc v0.8.0/go.mod h1:uLoCtb9J+EyAqh+26kdrTgmzRBFPGOolLWKpdxkKq+c=
github.com/zserge/webview v0.0.0-20191103184548-1a9ebffc2601 h1:64QY2+QvOmOMbcCU3cyn7T+4Af0RehxMfedEwarpV1Y=
github.com/zserge/webview v0.0.0-20191103184548-1a9ebffc2601/go.mod h1:a1CV8KR4Dd1eP2g+mEijGOp+HKczwdKHWyx0aPHKvo4=
26 changes: 14 additions & 12 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,19 @@ package main
import "github.com/zserge/webview"

func main() {
// Webview options:
// - name: Yandex.Music Desktop
name := "Yandex.Music Desktop"
// - URL to login screen: https://passport.yandex.com/auth?...
url := "https://passport.yandex.com/auth?origin=music_button-header&retpath=https%3A%2F%2Fmusic.yandex.com%2Fhome"
// - sizes: 800x800 px
width := 800
height := 800
// - resizable: true
resizable := true
// URL params
p := "origin=music_button-header&retpath=https%3A%2F%2Fmusic.yandex.com%2Fhome"

// Let's open window app with options:
webview.Open(name, url, width, height, resizable)
// Init app with webview options
w := webview.New(webview.Settings{
Title: "Yandex.Music Desktop",
URL: "https://passport.yandex.com/auth?" + p,
Width: 800,
Height: 960,
Resizable: true,
Debug: false,
})

// Run app
w.Run()
}

0 comments on commit 05f77fa

Please sign in to comment.