Git Product home page Git Product logo

Comments (6)

asmagill avatar asmagill commented on June 2, 2024

Can you post your code (or the relevant segment)? I'm not seeing this...

> hs.settings.set("BrainFart", "abc")


> hs.settings.get("BrainFart")
abc

> hs.settings.set("BrainFart2", "Abc")


> hs.settings.get("BrainFart2")
Abc

I have noticed problems with including periods in the setting key name (IIRC related to watching them with hs.settings.watchKey) but never with uppercase in the key or value name...

from hammerspoon.

danielo515 avatar danielo515 commented on June 2, 2024

Ok, maybe an edge case where I accidentally set it first using camel case and then I was not able to use it again with PascalCase?

>  hs.settings.set("brainFart", "abc")

> hs.settings.get("brainFart")
abc

> hs.settings.set("BrainFart", "Abc")

> hs.settings.get("BrainFart")
Abc

> hs.settings.get("brainFart")
abc

Ok, nope. Does it matter that I'm doing this from within a spoon and I'm using the SpoonName as key?

from hammerspoon.

danielo515 avatar danielo515 commented on June 2, 2024

Ok, something is now wrong with my spoon setting settings, now they are not stored at all. Do you mind having a look at it? https://github.com/danielo515/StreamDeckButton.spoon/blob/main/init.lua

from hammerspoon.

latenitefilms avatar latenitefilms commented on June 2, 2024

This line looks wrong:

https://github.com/danielo515/StreamDeckButton.spoon/blob/7127c8916f4272c678e6882696c6c401869b180d/init.lua#L54

You should be providing the key and value?

from hammerspoon.

danielo515 avatar danielo515 commented on June 2, 2024

Oh, dam it, how can I be so dumb?

from hammerspoon.

danielo515 avatar danielo515 commented on June 2, 2024

That was indeed the problem. That is one of the things I hate about Lua, and why I try to not code anything complex in it. Probably will have to write some Haxe bindings for some type safety here 😂
Thanks for your help

from hammerspoon.

Related Issues (20)

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.