Giter Site home page Giter Site logo

Not a valide command about slack_applescript HOT 2 OPEN

samknight avatar samknight commented on July 18, 2024
Not a valide command

from slack_applescript.

Comments (2)

MrDesjardins avatar MrDesjardins commented on July 18, 2024 1

For people having the same issue, instead of using the slack applescript library, I wrote an AppleScript that performs mostly what this library is trying to perform. It's my first AppleScript so, might not be the best code (got an issue with space that I fixed by explicitly sending 49 but it works.

tell application "Slack"
	activate
end tell

tell application "System Events"
	keystroke "/"
	keystroke "update"
	key code 49
	keystroke "your"
	key code 49
	keystroke "status"
	delay 1
	key code 76
	delay 1
	set textBuffer to "Hello world!"
	repeat with i from 1 to count characters of textBuffer
		if character i of textBuffer = " " then
			key code 49
		else
			keystroke (character i of textBuffer)
		end if
		delay 0.05
	end repeat
	delay 0.1
	key code 76
end tell

from slack_applescript.

samknight avatar samknight commented on July 18, 2024

Thanks for assisting others @MrDesjardins

What do you think is causing the issue from my library - I've assumed in the past it's a timing issue

from slack_applescript.

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.