smhg / sublime-suncycle

Sublime Text layout switch based on sunrise and sunset at your location.
MIT License
12 stars 6 forks source link

Theme stays on day setting, potential IP issue. #11

Open JonathanPort opened 7 years ago

JonathanPort commented 7 years ago

Somethings not right with my installation. I've added the correct settings in the plugins user settings:

{
    "day": {
        "color_scheme": "Packages/Material Theme/schemes/Material-Theme-Lighter.tmTheme",
        "theme": "Material-Theme-Lighter.sublime-theme",
    },
    "night": {
        "color_scheme": "Packages/Colorsublime - Themes/Facebook.tmTheme",
        "theme": "Material-Theme-Palenight.sublime-theme",
    }
}

But the theme, no matter what time of day/night, stays on the 'day' setting. I'm assuming this is an IP issue and so i'd like to set my location manually. How do I do that? I don't see any documentation or instructions on how to do that?

Love the plugin! Let me know asap :)

Cheers, Jon

smhg commented 7 years ago

The IP lookup isn't very stable as (free) lookup providers come and go. Depending on the usage of the plugin, this should be improved. Sad to say, but I no longer use it myself. So a PR or fork from someone is likely the best way to improve this.

Concerning the fixed location configuration, that should be easy:

{
    "latitude": 51.2838,
    "longitude": 0,
    "day": {
        "color_scheme": "Packages/Material Theme/schemes/Material-Theme-Lighter.tmTheme",
        "theme": "Material-Theme-Lighter.sublime-theme",
    },
    "night": {
        "color_scheme": "Packages/Colorsublime - Themes/Facebook.tmTheme",
        "theme": "Material-Theme-Palenight.sublime-theme",
    }
}

The latitude and longitude parameters are what you need to specify (it's in the readme).

JonathanPort commented 7 years ago

Ahh brilliant! Thanks so much for the info and help, appreciate it!

Jon