Git Product home page Git Product logo

vscode-sundial's Introduction

🌚 Sundial 🌝

Change your VS Code theme/settings based on your sunset, sunrise, system appearance or other preferences!

Visual Studio Marketplace Rating (Stars) Visual Studio Marketplace Downloads

Sundial changes your theme and VS Code settings (if needed) based on your day and night cycle or other options, you choose. It is inspired by the OSX Mojave dynamic backgrounds and Night Owl for Mac. It should reduce eye pain when working in the night or on the day. Humans should not strain their eyes too much, it's not recommended to have a light theme in the night and vice versa.

Whenever you have ideas for this project, things you would like to add or you found a bug, feel free to create an issue or start contributing! πŸ˜‡

The minimum supported VS Code version is 1.74.3

Buy me a Gluten-free Bread

VSCode Sundial

Installation

You can simply install any VS Code extension via the VS Code Marketplace. Just click the banner below:

Install VS Code extension Sundial

⚠️ IMPORTANT: Since VS Code 1.42.0 automatically changing the theme based on OS appearance is build in, if you want to use this plugin anyway you must disable this options with "window.autoDetectColorScheme": false

Keybindings

Sundial contributes the following keybindings:

Platform Keybinding Description
Windows ctrl+alt+t Toggles between your day/night theme.
Mac ctrl+cmd+t Toggles between your day/night theme.

Note: Whenever you use one of these keybindings, Sundial will be disabled.

Commands

Sundial contributes the following commands:

Command Description
Sundial: Switch to night theme πŸŒ‘ Switches to your night theme.
Sundial: Switch to day theme πŸŒ• Switches to your day theme.
Sundial: Toggle Day/Night Theme Toggles between your day/night theme.
Sundial: Enable extension Continues automation and enables extension.
Sundial: Disable extension Disables extension.
Sundial: Pause until next circle Pause until next day/night circle.

Note: Whenever you use one of the first three commands, Sundial will disable its automatic checks.

Settings

Sundial contributes the following settings:

Setting Default Description
workbench.preferredLightColorTheme Default Light+ Name of the theme of choice for your day work.
workbench.preferredDarkColorTheme Default Dark+ Name of the theme of choice for your night work.
sundial.sunrise 07:00 Set a time when your day starts in 24 hours format.
sundial.sunset 19:00 Set a time when your night starts in 24 hours format.
sundial.dayVariable 0 Set a variable to change the theme X minutes before or after sunrise.
sundial.nightVariable 0 Set a variable to change the theme X minutes before or after sunset.
sundial.daySettings {} An object of VSCode settings applied on the day.
sundial.nightSettings {} An object of VSCode settings applied on the night.
sundial.statusBarItemPriority 100 Set the status bar icon position (higher mean more left).
sundial.interval 5 Set a interval in which sundial should check the time in minutes.

⚠️ Don't forget to set "window.autoDetectColorScheme": false

If you set the interval to zero (0) sundial will not periodically check the time but still when VS Code triggers some editor events.

Any changes to sundial or VS Code settings will re-enable Sundial.

On both daySettings and nightSettings they will override your Workbench VSCode settings. Please make sure both have the same properties otherwise they will not change since Sundial is not remembering the settings you have set before!

Automatically set by current location

Sundial will fetch your geolocation from ip-api.

Setting Default Description
sundial.autoLocale false Updates your location based on your geolocation.

Automatically set by latitude and longitude

You can get your geolocation from ip-api or any other map service.

Setting Default Description
sundial.latitude ⊘ e.g. "50.110924"
sundial.longitude ⊘ e.g. "8.682127"

Automatically set by OS appearance

Since VS Code version 1.42.0 it is now build in so you don't need this extension for this options.

{
  "window.autoDetectColorScheme": true
}

Read more about the implementation here:

VS Code Settings

You can change your VS Code settings depending on your circle, this comes pretty handy if you have issues ready a font size of 12 in the night.

{
  "sundial.daySettings": {
    "editor.fontSize": 12
  },
  "sundial.nightSettings": {
    "editor.fontSize": 14
  }
}

Execution order

Sundial will check your settings in the following order and if one setting is present the next coming will be ignored.

  1. sundial.latitude and sundial.longitude
  2. sundial.autoLocale
  3. sundial.sunrise and sundial.sunset

Status bar icon

Status bar icon

Sundial will show a status bar icon that will toggle the current theme on click. This will also disable all sundial automated checks.

Examples

{
  "window.autoDetectColorScheme": false, // required!
  "workbench.preferredLightColorTheme": "Default Light+",
  "workbench.preferredDarkColorTheme": "Default Dark+",
  "sundial.interval": 20,
  "sundial.autoLocale": true
}
{
  "window.autoDetectColorScheme": false, // required!
  "workbench.preferredLightColorTheme": "Default Light+",
  "workbench.preferredDarkColorTheme": "Default Dark+",
  "sundial.sunrise": "05:12"
}
{
  "window.autoDetectColorScheme": false, // required!
  "workbench.preferredLightColorTheme": "Default Light+",
  "workbench.preferredDarkColorTheme": "Default Dark+",
  "sundial.dayVariable": 43,
  "sundial.latitude": "50.110924",
  "sundial.longitude": "8.682127",
  "sundial.daySettings": {
    "editor.fontSize": 13
  },
  "sundial.nightSettings": {
    "editor.fontSize": 15
  }
}

Development

I am working with esbuild to bundle Sundial to the smallest possible size to increase the load time in VS Code for you.

The minimum supported VS Code version is 1.74.3

  1. Install packages via npm: npm run install (pnpm does not work due to this VSCE Issue)
  2. Run debugger => Launch Extension
    • View the Extension Host and adjust settings to test or
    • Change a file and save it, let it compile
  3. Commit your changes with a detailed explanation
  4. Create a pull request

Package size: 279.8kb

Deployment

We use release-it to create a new release. This will automatically create a tag, release and new changelog for us.

pnpm release-it --help

Sundial is deployed on VS Code Marketplace and Open VSX.

  • VS Code Marketplace:
    • vsce publish
  • Open VSX:
    • vsce package
    • ./node_modules/.bin/ovsx publish *.vsix -p TOKEN

Pre-release

We update our version with release-it, so we must use some additional flags for vsce. The version must be without pre-release identifier, because VS Code Marketplace does not allow those.

pnpm vsce publish --pre-release --no-git-tag-version --no-update-package-json <pre_release_version>

Commits

Sundial follows the config-conventional spec.

vscode-sundial's People

Contributors

greenkeeper[bot] avatar muuvmuuv avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

vscode-sundial's Issues

An in-range update of @types/node is breaking the build 🚨

The devDependency @types/node was updated from 11.13.6 to 11.13.7.

🚨 View failing branch.

This version is covered by your current version range and after updating it in your project the build failed.

@types/node is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.

Status Details
  • ❌ WhiteSource Security Check: The Security Check found 1 vulnerabilities.

Severity CVSS Score CVE GitHub Issue
Medium 5.0 WS-2019-0032 #15

FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

An in-range update of ts-node is breaking the build 🚨

The devDependency ts-node was updated from 8.0.3 to 8.1.0.

🚨 View failing branch.

This version is covered by your current version range and after updating it in your project the build failed.

ts-node is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.

Status Details
  • ❌ WhiteSource Security Check: The Security Check found 2 vulnerabilities.

Severity CVSS Score CVE GitHub Issue
Medium 5.0 [WS-2019-0032]( "Go to CVE Details") #15
Medium 5.0 [WS-2019-0047]( "Go to CVE Details") #19

Commits

The new version differs by 4 commits.

  • d117650 8.1.0
  • 66d54af Cache file system operations (#803)
  • 038f83d Remove incremental & tsBuildInfoFile compiler opts (#815)
  • 750ecca Add --log-error option (#818)

See the full diff

FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

Reset timer after vscode action is triggered and optimize trigger times

I noticed that sometimes Sundial is called 3 times(!!!) because two vscode events are triggered and when the vscode.interval is at zero. We could reset the interval everytime a event is triggered and should consider refactoring the events and look for some better alternatives to not trigger it that often

[FEATURE] Allow to manually switch theme until next cycle

Is your feature request related to a problem? Please describe.

Whenever I manually switch to some other theme, immediately the extensions switches back to the Sundial Day/Night Theme. But for some files I really like to switch the Color Theme, because the syntax highlighting is more appropriate.

Describe the solution you'd like

I would like to be able to switch manually the Color Theme without Sundial automatically switching the theme until the next theme switching event (when the extensions switches to the Day/Night theme). For example if I switch manually the theme at 3pm, I want it to stay so until 6 pm when the Sundial dark theme kicks in.

Describe alternatives you've considered

I tried removing all event in the sundial.windowEvent and sundial.workspaceEvents, but it didn't work.

"sundial.windowEvents": [],
"sundial.workspaceEvents": []

Turning off auto-selection of a theme?

Is it possible to turn off the auto-selection between night and day themes?

I want to manually switch the theme so that whenever I open the vscode, just the previous theme is used.

An in-range update of webpack-build-notifier is breaking the build 🚨

The devDependency webpack-build-notifier was updated from 0.1.31 to 0.1.32.

🚨 View failing branch.

This version is covered by your current version range and after updating it in your project the build failed.

webpack-build-notifier is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.

Status Details
  • ❌ WhiteSource Security Check: The Security Check found 1 vulnerabilities.

Severity CVSS Score CVE GitHub Issue
Medium 5.0 [WS-2019-0032]( "Go to CVE Details") #15

Commits

The new version differs by 1 commits.

See the full diff

FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

Modify settings.json depending on night/day

I'm using the extension Bracket Pair Colorizer to color pairs of brackets in the editor. The problem is that colors that work well at night don't work well during daytime. These colors can be changed by modifying the file settings.json.

I think a good feature would be to add a new option for sundial in which you can specify lines to add/remove to the settings.json file depending of the time of the day.

[FEATURE] Move extension logs to Output card

Is your feature request related to a problem? Please describe.

The extension currently floods the Debug Console with non-error messages. This is quite frustrating when I try to debug problems with my own extensions or VSCode.
Screenshot_20200130_194954
image

Describe the solution you'd like

Other extensions print this kind of information on the Output card e.g.:

image

How to ignore terminal?

Hey, great extension made me finally switch to vsc from atom ;)

How can I set it up, that I have a fixed (no day/night change) theme of my choice for the terminal in vsc?

Open VSX Listing: Signing the Publisher Agreement

Thank you for being part of the Open VSX community by adding your extensions to the Open VSX Registry. Please note that the service was recently transferred to the Eclipse Foundation and urgent action on your part is needed so we can continue to list your extensions. To ensure uninterrupted service, please sign the Eclipse Publisher Agreement on or before January 8, 2021. If not signed by that date, your extensions will be delisted and will no longer appear on the site nor be available via the API. If you sign at a later date, your extensions will then be re-activated. The signing process is explained in the Wiki (steps 1 and 2).

Please also note that all extensions MUST have a license in order to be listed.

More details are in these recent blog posts:
https://blogs.eclipse.org/post/brian-king/open-vsx-registry-under-new-management
https://blogs.eclipse.org/post/brian-king/new-era-open-vsx-registry

Today, there’s growing momentum around open source tools and technologies that support Visual Studio (VS) Code extensions. Leading global organizations are adopting these tools and technologies. This momentum has spurred demand for a marketplace without restrictions and limitations. Thanks for joining us on this journey as we continue to build the Open VSX community. We look forward to continued innovation from you in 2021!

[BUG] When connected to a VPN the extension cannot fetch location

Describe the bug

When the option Auto locale is active and a VPN connection is also active the extension throws an exception.
This forces the extension to set the wrong theme and we have disabled the option Auto locale and entered manual coordinates or time for proper behavior.
At first it seemed like this could be solved by not using a VPN to establish a connection and use the one on cache, given the error description. After trying that approach the error persists.

To Reproduce

Steps to reproduce the behavior:

  1. Open VS Code
  2. Go to extension settings
  3. Enable 'Auto locale'
  4. Connect to a VPN location
  5. There should be a notification/pop up displaying an error

Expected behavior

No error notification and configured theme displayed according to geo-location.

Screenshots

image

Desktop (please complete the following information):

  • OS: Windows 11 21H2 build 22000.434
  • VS Code: 1.63.2
  • Sundial: 2.6.2

WS-2019-0047 Medium Severity Vulnerability detected by WhiteSource

WS-2019-0047 - Medium Severity Vulnerability

Vulnerable Library - tar-2.2.1.tgz

tar for node

Library home page: http://registry.npmjs.org/tar/-/tar-2.2.1.tgz

Path to dependency file: /package.json

Path to vulnerable library: /tmp/git/vscode-sundial/node_modules/tar/package.json

Dependency Hierarchy:

  • vscode-1.1.30.tgz (Root Library)
    • gulp-untar-0.0.7.tgz
      • ❌ tar-2.2.1.tgz (Vulnerable Library)

Found in HEAD commit: b80ef33c3acce6d426c425738b353cb9a345d9d8

Vulnerability Details

Versions of node-tar prior to 4.4.2 are vulnerable to Arbitrary File Overwrite. Extracting tarballs containing a hardlink to a file that already exists in the system, and a file that matches the hardlink will overwrite the system's file with the contents of the extracted file.

Publish Date: 2019-04-05

URL: WS-2019-0047

CVSS 2 Score Details (5.0)

Base Score Metrics not available

Suggested Fix

Type: Upgrade version

Origin: https://www.npmjs.com/advisories/803

Release Date: 2019-04-05

Fix Resolution: 4.4.2


Step up your Open Source Security Game with WhiteSource here

[FEATURE] Multiple light and dark themes

Describe the solution you'd like

It'd be nice if you can set list of light and dark themes and every time it switches it picks a random one

Describe alternatives you've considered

You'd have to change it manually otherwise

Additional context

Add any other context or screenshots about the feature request here.

An in-range update of webpack-cli is breaking the build 🚨

The devDependency webpack-cli was updated from 3.3.0 to 3.3.1.

🚨 View failing branch.

This version is covered by your current version range and after updating it in your project the build failed.

webpack-cli is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.

Status Details
  • ❌ WhiteSource Security Check: The Security Check found 1 vulnerabilities.

Severity CVSS Score CVE GitHub Issue
Medium 5.0 WS-2019-0032 #15

Commits

The new version differs by 74 commits.

  • d3f8e20 chore: v.3.1.1
  • f371e72 Merge pull request #847 from anshumanv/846
  • da9e732 Merge pull request #841 from pranshuchittora/docs-remove
  • cb68b1b docs(serve): link to webpack-dev-server
  • f7451d4 docs(serve): update docs to use webpack-dev-server
  • 06b4929 Remove tslint in favour of eslint (#834)
  • 8c1db03 chore(docs): removes scaffolding docs from the root
  • dc941e6 docs(contributing): fixes dead link (#835)
  • b8d5511 Merge pull request #832 from pranshuchittora/docs
  • 6a0375a docs(packages): adds downloads/month shield
  • 963c85f Merge pull request #818 from pranshuchittora/refactor-utils
  • 8506ccf Merge pull request #827 from rishabh3112/patch-9
  • 6816057 chore(deps): upgrade lerna to fix vulnerabilities & update webpack-dev-server (#823)
  • 834d90e Merge pull request #828 from pranshuchittora/shields
  • 958d064 docs(readme): adds contributors shield

There are 74 commits in total.

See the full diff

FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

Feature request: Automatically change depending on sunset?

This is an amazing plugin (especially since VSCode don't support Mojave's native dark mode..). I live up in the cold north, and the time of daylight changes quite fast, so manually editing when it is supposed to change form light to dark would almost require me to do it everyday if I wanted it to be in sync with the sunlight outside.

Would it be possible, perhaps, to have the function to change to dark when the sun sets rather than at a predefined time? There is a nice little programme that does this for the OS, https://nightowl.kramser.xyz, and f.lux and the native night shift have been doing it since long.

An in-range update of webpack is breaking the build 🚨

The devDependency webpack was updated from 4.29.6 to 4.30.0.

🚨 View failing branch.

This version is covered by your current version range and after updating it in your project the build failed.

webpack is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.

Status Details
  • ❌ WhiteSource Security Check: The Security Check found 2 vulnerabilities.

Severity CVSS Score CVE GitHub Issue
Medium 5.0 [WS-2019-0032]( "Go to CVE Details") #15
Medium 5.0 [WS-2019-0047]( "Go to CVE Details") #19

Release Notes for v4.30.0

Features

  • add amd: false to disable AMD support
  • Compilation.hooks.finishModules now also allows async plugins
  • add output.libraryTarget: "system" to compile for SystemJs environment

Bugfixes

  • fix generating a null id when concatenating an entry module in a different chunk
  • fix unneeded chunk references when splitting modules from chunks
  • fix parsing of function name in function scope

Performance

  • Lazy require some internal files
  • Faster way to generate function headers

Contributing

  • Run prettier on examples markdown
Commits

The new version differs by 102 commits.

  • b72b96a 4.30.0
  • 9ededfa Merge pull request #9034 from webpack/dependabot/npm_and_yarn/tapable-1.1.3
  • e33a91f chore(deps): bump tapable from 1.1.1 to 1.1.3
  • de81dd0 Merge pull request #8864 from joeldenning/issue-8833
  • 7dfddc2 Merge pull request #8858 from webpack/dependabot/npm_and_yarn/json-schema-to-typescript-6.1.3
  • f7d0c25 Improve way how System is tested
  • 39a680d formating of output code
  • e2e74f5 Merge pull request #8980 from webpack/dependabot/npm_and_yarn/eslint-5.16.0
  • 81dc70d Merge pull request #9022 from sandersn/fix-webassembly-declaration
  • 13aa512 Merge pull request #9023 from webpack/dependabot/npm_and_yarn/typescript-3.4.3
  • 1566036 chore(deps-dev): bump typescript from 3.4.2 to 3.4.3
  • ce33ca7 Update WebAssembly declaration
  • 5117461 Merge pull request #9006 from hiroppy/feature/fix-template-syntax
  • 9e60850 Merge pull request #8984 from webpack/dependabot/npm_and_yarn/react-16.8.6
  • 5f75527 Bump json-schema-to-typescript from 6.1.1 to 6.1.3

There are 102 commits in total.

See the full diff

FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

An in-range update of @types/got is breaking the build 🚨

The devDependency @types/got was updated from 9.4.3 to 9.4.4.

🚨 View failing branch.

This version is covered by your current version range and after updating it in your project the build failed.

@types/got is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.

Status Details
  • ❌ WhiteSource Security Check: The Security Check found 1 vulnerabilities.

Severity CVSS Score CVE GitHub Issue
Medium 5.0 WS-2019-0032 #15

FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

sundial.systemTheme causes lag when VSCode is opened from iTerm

Describe the bug

When `"sundial.systemTheme" is enabled, there is a noticeable lag when switching between editors.

To Reproduce

Steps to reproduce the behavior:

  1. Open VSCode from iTerm2 (i.e. using code .)
  2. Set "sundial.systemTheme: true" in settings
  3. Create a new split (cmd+\).
  4. Quickly switch focus repeatedly using "cmd+1" and "cmd+2"

Expected behavior

No noticeable lag.

Desktop (please complete the following information):

  • OS: [e.g. macOS 10.14.5]
  • VS Code [e.g. 1.3.5]
  • iTerm2 Build 3.3.20190124-nightly

rejected promise not handled within 1 second: TimeoutError

rejected promise not handled within 1 second: TimeoutError: Timeout awaiting 'request' for 5000ms
extensionHostProcess.js:700
stack trace: TimeoutError: Timeout awaiting 'request' for 5000ms
extensionHostProcess.js:700
	at ClientRequest.module.exports../node_modules/got/source/request-as-event-emitter.js.e.exports.n.once.t (/Users/marvinheilemann/.vscode/extensions/muuvmuuv.vscode-sundial-1.3.0/dist/extension.js:11:63981)
	at Object.onceWrapper (events.js:273:13)
	at ClientRequest.emit (events.js:187:15)
	at ClientRequest.module.exports../node_modules/@szmarczak/http-timer/source/index.js.e.exports.e.emit.a (/Users/marvinheilemann/.vscode/extensions/muuvmuuv.vscode-sundial-1.3.0/dist/extension.js:11:6506)
	at Immediate._ (/Users/marvinheilemann/.vscode/extensions/muuvmuuv.vscode-sundial-1.3.0/dist/extension.js:11:66803)
	at runCallback (timers.js:697:11)
	at tryOnImmediate (timers.js:667:5)
	at processImmediate (timers.js:649:5)

An in-range update of @types/got is breaking the build 🚨

The devDependency @types/got was updated from 9.4.2 to 9.4.3.

🚨 View failing branch.

This version is covered by your current version range and after updating it in your project the build failed.

@types/got is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.

Status Details
  • ❌ WhiteSource Security Check: The Security Check found 1 vulnerabilities.

Severity CVSS Score CVE GitHub Issue
Medium 5.0 WS-2019-0032 #15

FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

[FEATURE] Doesn't appear in the search "auto night mode" on extensions store

OK, not quite a "feature request", but I found your extension completely by luck, because if one searches "auto night mode" in the extensions, this doesn't appear in the vscode's results, or at least not in the top ~20 ones or so(I don't usually go deep down).

I don't know how, but maybe you could add some keywords or something like that so that it gets brought up when people search for it? I just want the people to find this and help their eyes. :)
(Thank you very much for this extension).

[BUG] Extension does not run after sunset

Describe the bug

No theme change after sunset. (haven't tested sunrise)

I verified that window.autoDetectColorScheme is not checked (default). I enabled the extension before sunset, but it is now 50 minutes past sunset and no theme change. Are there logs somewhere I can look at?

Desktop (please complete the following information):

Version: 1.52.1 (user setup)
Commit: ea3859d4ba2f3e577a159bc91e3074c5d85c0523
Date: 2020-12-16T16:34:46.910Z
Electron: 9.3.5
Chrome: 83.0.4103.122
Node.js: 12.14.1
V8: 8.3.110.13-electron.0
OS: Windows_NT x64 10.0.19042

Here are my settings for Sundial v2.3.0:

    "workbench.preferredDarkColorTheme": "Cobalt2",
    "sundial.nightVariable": 20,
    "sundial.latitude": "47.6",
    "sundial.longitude": "-122.3"

Add offline support

Would be great if somehow Sundial could change the theme without an internet connection and throws an info message in the console that the connection is down.

WS-2019-0034 Medium Severity Vulnerability detected by WhiteSource

WS-2019-0034 - Medium Severity Vulnerability

Vulnerable Library - js-yaml-3.12.2.tgz

YAML 1.2 parser and serializer

path: /tmp/git/vscode-sundial/node_modules/js-yaml/package.json

Library home page: https://registry.npmjs.org/js-yaml/-/js-yaml-3.12.2.tgz

Dependency Hierarchy:

  • tslint-5.14.0.tgz (Root Library)
    • ❌ js-yaml-3.12.2.tgz (Vulnerable Library)

Found in HEAD commit: bc0c4634e02c47558d6e0204dfa10707b0cae370

Vulnerability Details

Versions js-yaml prior to 3.13.0 are vulnerable to Denial of Service. By parsing a carefully-crafted YAML file, the node process stalls and may exhaust system resources leading to a Denial of Service.

Publish Date: 2019-03-31

URL: WS-2019-0034

CVSS 2 Score Details (5.0)

Base Score Metrics not available

Suggested Fix

Type: Upgrade version

Origin: https://www.npmjs.com/advisories/788

Release Date: 2019-03-31

Fix Resolution: 3.13.0


Step up your Open Source Security Game with WhiteSource here

Cannot read property 'globalState' of undefined

Seems its not longer working with autoLocale:

[Extension Host] rejected promise not handled within 1 second: TypeError: Cannot read property 'globalState' of undefined
t.log @ console.ts:134
$logExtensionHostMessage @ mainThreadConsole.ts:39
_doInvokeHandler @ rpcProtocol.ts:390
_invokeHandler @ rpcProtocol.ts:375
_receiveRequest @ rpcProtocol.ts:295
_receiveOneMessage @ rpcProtocol.ts:225
_protocol.onMessage.e @ rpcProtocol.ts:100
fire @ event.ts:584
r @ ipc.net.ts:295
e @ ipc.net.ts:302
fire @ event.ts:584
o @ ipc.net.ts:103
_socketDataListener.e @ ipc.net.ts:132
emit @ events.js:182
addChunk @ _stream_readable.js:279
readableAddChunk @ _stream_readable.js:264
Readable.push @ _stream_readable.js:219
onread @ net.js:636
console.ts:134 [Extension Host] stack trace: TypeError: Cannot read property 'globalState' of undefined
	at Sundial.<anonymous> (/Users/marvinheilemann/.vscode/extensions/muuvmuuv.vscode-sundial-1.2.1/out/sundial.js:96:47)
	at Generator.next (<anonymous>)
	at fulfilled (/Users/marvinheilemann/.vscode/extensions/muuvmuuv.vscode-sundial-1.2.1/out/sundial.js:4:58)
t.log @ console.ts:134
$logExtensionHostMessage @ mainThreadConsole.ts:39
_doInvokeHandler @ rpcProtocol.ts:390
_invokeHandler @ rpcProtocol.ts:375
_receiveRequest @ rpcProtocol.ts:295
_receiveOneMessage @ rpcProtocol.ts:225
_protocol.onMessage.e @ rpcProtocol.ts:100
fire @ event.ts:584
r @ ipc.net.ts:295
e @ ipc.net.ts:302
fire @ event.ts:584
o @ ipc.net.ts:103
_socketDataListener.e @ ipc.net.ts:132
emit @ events.js:182
addChunk @ _stream_readable.js:279
readableAddChunk @ _stream_readable.js:264
Readable.push @ _stream_readable.js:219
onread @ net.js:636
mainThreadExtensionService.ts:49 [[object Object]]Cannot read property 'globalState' of undefined
$onExtensionRuntimeError @ mainThreadExtensionService.ts:49
_doInvokeHandler @ rpcProtocol.ts:390
_invokeHandler @ rpcProtocol.ts:375
_receiveRequest @ rpcProtocol.ts:295
_receiveOneMessage @ rpcProtocol.ts:225
_protocol.onMessage.e @ rpcProtocol.ts:100
fire @ event.ts:584
r @ ipc.net.ts:295
e @ ipc.net.ts:302
fire @ event.ts:584
o @ ipc.net.ts:103
_socketDataListener.e @ ipc.net.ts:132
emit @ events.js:182
addChunk @ _stream_readable.js:279
readableAddChunk @ _stream_readable.js:264
Readable.push @ _stream_readable.js:219
onread @ net.js:636
mainThreadExtensionService.ts:50 TypeError: Cannot read property 'globalState' of undefined
	at Sundial.<anonymous> (/Users/marvinheilemann/.vscode/extensions/muuvmuuv.vscode-sundial-1.2.1/out/sundial.js:96)
	at Generator.next (<anonymous>)
	at fulfilled (/Users/marvinheilemann/.vscode/extensions/muuvmuuv.vscode-sundial-1.2.1/out/sundial.js:4)

Write tests

Would be nice to have some automated tests before every publish.

I don't have much experience in this with VS Code, so I hope someone will contribute or help me to get in the right direction. Especially with things like; tell VS Code it's in the night now

Cannot read property 'theme' of undefined

[Extension Host] Sundial async check initialized...
console.ts:136 [Extension Host] Sundial will now use your configurated location
console.ts:136 [Extension Host] Sundial applied your day theme! πŸŒ•
console.ts:136 [Extension Host] rejected promise not handled within 1 second
t.log @ console.ts:136
t._logExtensionHostMessage @ extensionHost.ts:438
(anonymous) @ extensionHost.ts:246
emitTwo @ events.js:126
emit @ events.js:214
emit @ internal/child_process.js:772
_combinedTickCallback @ internal/process/next_tick.js:141
_tickCallback @ internal/process/next_tick.js:180
log.ts:171   ERR Cannot read property 'theme' of undefined: TypeError: Cannot read property 'theme' of undefined
    at Sundial.changeThemeTo (/Users/marvinheilemann/.vscode/extensions/muuvmuuv.vscode-sundial-1.1.1/out/sundial.js:141:47)
    at Sundial.<anonymous> (/Users/marvinheilemann/.vscode/extensions/muuvmuuv.vscode-sundial-1.1.1/out/sundial.js:67:22)
    at Generator.next (<anonymous>)
    at fulfilled (/Users/marvinheilemann/.vscode/extensions/muuvmuuv.vscode-sundial-1.1.1/out/sundial.js:4:58)
    at <anonymous>

[BUG] – Continuous errors when offline

Describe the bug

I have continuous pop-up errors when I am working in VSCode, as your extension unsuccessfully tries to reach some server for the automatic geo-location.

To Reproduce

Go offline, wake up the computer from sleep, do not connect to wifi, and have enabled automatic geolocation for this extension.

Expected behavior

It should remember the data from the last sync with the geolocation server, if the data is for example older than 10 days (think about holidays), it should have a fallback option to the manual time settings.

Screenshots

If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • MS Windows 10 1903 Build 18362
  • VS Code 1.40.2

Error: Setting has invalid type, expected "string". Fix in JSON.

Themes are not auto-updating.

The themes are not auto-updating and there is the following error message on the settings pane:

Setting has invalid type, expected "string". Fix in JSON..

Some other functionality appears to work, namely that I can use ctrl+cmd+t to switch btw light and dark themes.

To Reproduce

Steps to reproduce the behavior:

  1. Install theme
  2. Go to Settings (cmd+,)
  3. See errors

Expected behavior

  1. The themes auto-switch.
  2. The error messages don't appear.

Screenshots

Here's the screenshot of the Settings pane, including the error messages:
image

Desktop (please complete the following information):

  • OS: macOS 10.15.4
  • VS Code:
Version: 1.45.0
Commit: d69a79b73808559a91206d73d7717ff5f798f23c
Date: 2020-05-07T15:57:33.467Z
Electron: 7.2.4
Chrome: 78.0.3904.130
Node.js: 12.8.1
V8: 7.8.279.23-electron.0
OS: Darwin x64 19.4.0
  • Sundial: 2.3.0

[FEATURE] Remove auto theme switch based on OS appearance

Is your feature request related to a problem? Please describe.

Because I'm going to implement this feature natively to VS Code, this isn't longer needed in Sundial.

Describe the solution you'd like

Remove it from Sundial core and add a hint that any other feature in Sundial would need the options in Code colorThemeAutoSwitch to be off (or whatever the option will be named in release)

Describe alternatives you've considered

None

Additional context

An in-range update of @types/node is breaking the build 🚨

The devDependency @types/node was updated from 11.13.0 to 11.13.1.

🚨 View failing branch.

This version is covered by your current version range and after updating it in your project the build failed.

@types/node is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.

Status Details
  • ❌ WhiteSource Security Check: The Security Check found 2 vulnerabilities.

Severity CVSS Score CVE GitHub Issue
Medium 5.0 [WS-2019-0032]( "Go to CVE Details") #15
Medium 5.0 [WS-2019-0047]( "Go to CVE Details") #19

FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

An in-range update of @types/node is breaking the build 🚨

The devDependency @types/node was updated from 11.13.5 to 11.13.6.

🚨 View failing branch.

This version is covered by your current version range and after updating it in your project the build failed.

@types/node is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.

Status Details
  • ❌ WhiteSource Security Check: The Security Check found 1 vulnerabilities.

Severity CVSS Score CVE GitHub Issue
Medium 5.0 WS-2019-0032 #15

FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

[BUG] Dark theme is applied instead of the light one

Describe the bug
See this please:
image
According to my timezone, it must turn on the light theme, but the dark theme is applied.

To Reproduce
Well, yesterday it worked correctly, but today it got my day/night wrong (at least apparently).

Expected behavior
Light theme must be on. Am I doing anything wrong?

Desktop (please complete the following information):

  • OS: [e.g. macOS 10.14.4] Windows 10
  • VS Code: [e.g. 1.33.1] 1.60.2
  • Sundial: [e.g. 1.16.0] 2.6.0

An in-range update of @types/inquirer is breaking the build 🚨

The devDependency @types/inquirer was updated from 6.0.0 to 6.0.1.

🚨 View failing branch.

This version is covered by your current version range and after updating it in your project the build failed.

@types/inquirer is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.

Status Details
  • ❌ WhiteSource Security Check: The Security Check found 1 vulnerabilities.

Severity CVSS Score CVE GitHub Issue
Medium 5.0 WS-2019-0032 #15

FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

WS-2019-0032 Medium Severity Vulnerability detected by WhiteSource

WS-2019-0032 - Medium Severity Vulnerability

Vulnerable Library - js-yaml-3.12.2.tgz

YAML 1.2 parser and serializer

path: /tmp/git/vscode-sundial/node_modules/js-yaml/package.json

Library home page: https://registry.npmjs.org/js-yaml/-/js-yaml-3.12.2.tgz

Dependency Hierarchy:

  • tslint-5.14.0.tgz (Root Library)
    • ❌ js-yaml-3.12.2.tgz (Vulnerable Library)

Found in HEAD commit: 3922198e39bbe653c4faa646ab26b0f11600cad0

Vulnerability Details

Versions js-yaml prior to 3.13.0 are vulnerable to Denial of Service. By parsing a carefully-crafted YAML file, the node process stalls and may exhaust system resources leading to a Denial of Service.

Publish Date: 2019-03-26

URL: WS-2019-0032

CVSS 2 Score Details (5.0)

Base Score Metrics not available

Suggested Fix

Type: Upgrade version

Origin: https://www.npmjs.com/advisories/788/versions

Release Date: 2019-03-26

Fix Resolution: 3.13.0


Step up your Open Source Security Game with WhiteSource here

An in-range update of @types/node is breaking the build 🚨

The devDependency @types/node was updated from 11.11.8 to 11.12.0.

🚨 View failing branch.

This version is covered by your current version range and after updating it in your project the build failed.

@types/node is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.

Status Details
  • ❌ WhiteSource Security Check: The Security Check found 1 vulnerabilities.

Severity CVSS Score CVE GitHub Issue
Medium 5.0 [WS-2019-0032]( "Go to CVE Details") #15

FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

An in-range update of @types/webpack is breaking the build 🚨

The devDependency @types/webpack was updated from 4.4.26 to 4.4.27.

🚨 View failing branch.

This version is covered by your current version range and after updating it in your project the build failed.

@types/webpack is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.

Status Details
  • ❌ WhiteSource Security Check: The Security Check found 1 vulnerabilities.

Severity CVSS Score CVE GitHub Issue
Medium 5.0 [WS-2019-0032]( "Go to CVE Details") #15

FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.