{ "info": { "author": "Hofstadter, Inc.", "author_email": "support@hofstadter.io", "bugtrack_url": null, "classifiers": [], "description": "# self-driving-desktop\n\nDesktop Automation Framework.\nDrive your keyboard and mouse with text files.\n\n```\npip install self-driving-desktop\n\nsdd playlist.txt [--record]\n```\n\n### Playlists\n\n```\n# Set screen size\nscreen \"1080p\";\n\n# Create Coordinates\ncoords {\n \"center\": {\n \"1080p\": [960, 540],\n \"720p\": [640, 360]\n }\n};\n\n# Import playlist files\nimport \"test/main.txt\";\n\n# Create a playlist\nplaylist \"openChrome\" {\n # Run programs in the shell\n shell \"google-chrome\";\n sleep 2.0;\n\n # Name the new window\n active \"hofChrome\";\n sleep 0.5;\n\n # Use hotkeys to arrange\n hotkeys \"winleft\" \"right\";\n sleep 1;\n};\n\nplaylist \"closeChrome\" {\n # Focus a named window\n focus \"hofChrome\";\n hotkeys \"alt\" \"f4\";\n sleep 1;\n};\n\nplaylist \"readTheDocs\" {\n # Go to a webpage\n focus \"hofChrome\";\n sleep 0.2;\n\n # Type the URL\n write \"https://docs.hofstadter.io\\n\" 0.05;\n\n # Goto an imported coordinate\n coord \"getting-started\" 0.5;\n};\n\n# Move the mouse in a square\nplaylist \"repeatTest\" {\n mm 100 100 1;\n mm 1000 100 1;\n mm 1000 500 1;\n mm 100 500 1;\n};\n\n# Our main playlist\nplaylist \"main\" {\n # Goto a named coordinate, also with offset\n coord \"center\" 1;\n coord \"center\" 250 -250 1;\n\n # Operate the browser\n play \"openChrome\";\n play \"readTheDocs\";\n play \"closeChrome\";\n\n # Play a playlist multiple times\n play \"repeatTest\" 4;\n\n};\n\n# Set the global delay between steps\ndelay 0.025;\n\n# Finally, play our main playlist\nplay \"main\";\n\n```\n\n### Grammar\n\n#### Top-level:\n\n- file has steps and playlists\n- steps are the only thing run\n- play runs a playlist\n\n```\n# relative imports from file\nimport \"relative/path.txt\";\n\n# named coordinates\ncoords {\n # coord name\n \"center\": {\n # screen identifier\n \"1080p\": [960, 540],\n \"720p\": [640, 360]\n }\n};\n\n# define playlists\nplaylist \"my-playlist\" {\n steps...;\n};\n\nplaylist \"main\" {\n steps...;\n # run playlists from playlists\n play \"my-playlist\"\n}\n\n# set the screen identifier\nscreen \"1080p\";\n\n# run a playlist\nplay \"my-playlist\" \"main\";\n```\n\n#### Steps:\n\n- `play \"name\" \"nameB\" ... [N];`: run one or more playlists, optionally repeat N times.\n- `delay x.y;`: set delay between steps to x.y seconds\n- `sleep x.y;`: sleep for x.y seconds\n- `screen \"screen\";`: set the screen resolution identifier\n- `shell \"quoted strings\"+;`: exec a command from the program\n\nwindows:\n\n- `active \"someName\";`: name the active window\n- `focus \"someName\";`: focus a named window\n\nmouse:\n\n- `mouse x y s;`: move the mouse to x,y in s seconds\n- `coord \"name\" s;`: move the mouse to a named coordinate in s seconds\n- `coord \"name\" x y s;`: move to a named coordinate with offset in s seconds\n- `click;`: click the left mouse button\n- `btnclick [left,middle,right];`\n- `btndown [left,middle,right];`\n- `btnup [left,middle,right];`\n- `drag [left,middle,right] x y s;`: drag the mouse to x,y in s seconds\n- `scroll n;`: scroll n lines, negative is up\n- `hscroll n;`: horizontal scroll n \"clicks\", negative is left\n\nkeyboard:\n\n- `keypress \"key\";`\n- `keydown \"key\";`\n- `keyup \"key\";`\n- `hotkeys \"quoted\" \"keys\" ...;`: press some keys together\n- `write \"quoted string\\n\";`: type a string, \"\\n\" is enter\n\nclipboard:\n\n- `copy;`, just `ctrl-c`\n- `paste;`, just `ctrl-v`\n- `save_clipboard \"name\";` save the clipboard contents to \"name\"\n- `load_clipboard \"name\";` load the clipboard contents from \"name\"\n- `copy_clipboard \"name\";` copy && save the clipboard contents to \"name\"\n- `paste_clipboard \"name\";` load the clipboard contents from \"name\" && paste\n\nall keys are from [pyautogui](https://pyautogui.readthedocs.io/en/latest/keyboard.html#keyboard-keys)\n\n[Grammer Definition](./self_driving_desktop/grammar.py)\n\n### Recording\n\nYou can record your mouse and keyboard\nto a playlist file by:\n\n```\nsdd record.txt --record\n```\n\n_Note, not all keys are working yet._\n\nA keymap to fix some is [here](./self_driving_desktop/keymap.py).\n\n### Development Setup\n\n```\nvirtualenv --python python3 penv\nsource penv/bin/activate\npip install -r requirements.txt\nexport PYTHONPATH=.\npython self_driving_desktop/__main__.py ...\n```", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/hofstadter-io/self-driving-desktop", "keywords": "desktop automation,automation,gui,mouse,keyboard,driver,recorder", "license": "", "maintainer": "", "maintainer_email": "", "name": "self-driving-desktop", "package_url": "https://pypi.org/project/self-driving-desktop/", "platform": "", "project_url": "https://pypi.org/project/self-driving-desktop/", "project_urls": { "Homepage": "https://github.com/hofstadter-io/self-driving-desktop" }, "release_url": "https://pypi.org/project/self-driving-desktop/0.0.7/", "requires_dist": null, "requires_python": "", "summary": "Desktop Automation Framework. Drive your keyboard and mouse with text files.", "version": "0.0.7" }, "last_serial": 5267061, "releases": { "0.0.2": [ { "comment_text": "", "digests": { "md5": "b4c69af5dcfb79a513a67c2e9369c6e2", "sha256": "23b77b44a9c208cc9a72d4417b9e4d96dc826547792916aeab2bd239e86a80d9" }, "downloads": -1, "filename": "self_driving_desktop-0.0.2-py3.6.egg", "has_sig": false, "md5_digest": "b4c69af5dcfb79a513a67c2e9369c6e2", "packagetype": "bdist_egg", "python_version": "3.6", "requires_python": null, "size": 6712, "upload_time": "2019-05-10T17:52:26", "url": "https://files.pythonhosted.org/packages/d9/26/4cf1c06efe295c4ce0908f74fe715e499b2ddd14dcf00491364db5d81f7b/self_driving_desktop-0.0.2-py3.6.egg" } ], "0.0.3": [ { "comment_text": "", "digests": { "md5": "6cb6dd6eba6c937c67b96e7dc050df1f", "sha256": "4f16780432d0f5bcf7286743eda83125bb3e1c8751080ad3e8342683cf7abbc1" }, "downloads": -1, "filename": "self_driving_desktop-0.0.3-py3.6.egg", "has_sig": false, "md5_digest": "6cb6dd6eba6c937c67b96e7dc050df1f", "packagetype": "bdist_egg", "python_version": "3.6", "requires_python": null, "size": 12622, "upload_time": "2019-05-11T01:46:00", "url": "https://files.pythonhosted.org/packages/93/fd/7e226cbbd7d34188aaf714a01e9f970f66cc5f7b9e23abb1a0ea08fc388d/self_driving_desktop-0.0.3-py3.6.egg" } ], "0.0.4": [ { "comment_text": "", "digests": { "md5": "1e3460d14c2e66c6c2c17f069ed58819", "sha256": "dcbb5fb1a93b57bad9731f5523ae131bcc4eed0c96419187382905ca3ef67d5e" }, "downloads": -1, "filename": "self_driving_desktop-0.0.4-py3.6.egg", "has_sig": false, "md5_digest": "1e3460d14c2e66c6c2c17f069ed58819", "packagetype": "bdist_egg", "python_version": "3.6", "requires_python": null, "size": 13664, "upload_time": "2019-05-11T02:25:39", "url": "https://files.pythonhosted.org/packages/b5/4e/238b4c4fbcee2bcd34aa1569f30be3f8ba73a071ccdadddd384d4a389aa5/self_driving_desktop-0.0.4-py3.6.egg" } ], "0.0.5": [ { "comment_text": "", "digests": { "md5": "95d977603050f41e7a02a4fdd859aeb7", "sha256": "cf134ad5140e3e99f50420a6f171ea9050b3149195515b46e0ae8b8ad6f3a9e5" }, "downloads": -1, "filename": "self_driving_desktop-0.0.5-py3.6.egg", "has_sig": false, "md5_digest": "95d977603050f41e7a02a4fdd859aeb7", "packagetype": "bdist_egg", "python_version": "3.6", "requires_python": null, "size": 13850, "upload_time": "2019-05-11T02:47:00", "url": "https://files.pythonhosted.org/packages/86/32/18bf030e3a6861fd8d44aad1863a773333d45d71ada34089d541250dc569/self_driving_desktop-0.0.5-py3.6.egg" } ], "0.0.6": [ { "comment_text": "", "digests": { "md5": "21b775cb4f1dedc0bc980b4409b28555", "sha256": "259d86ac9480204eb00256d1ced38d7200391a9cb4e705e4feca5b627fef95e1" }, "downloads": -1, "filename": "self_driving_desktop-0.0.6-py3.6.egg", "has_sig": false, "md5_digest": "21b775cb4f1dedc0bc980b4409b28555", "packagetype": "bdist_egg", "python_version": "3.6", "requires_python": null, "size": 15737, "upload_time": "2019-05-11T21:08:36", "url": "https://files.pythonhosted.org/packages/1e/39/ece7786730e9bcb1f693f1d90d4aa494c38f7dcc624544cffe6e038090f2/self_driving_desktop-0.0.6-py3.6.egg" } ], "0.0.7": [ { "comment_text": "", "digests": { "md5": "3c6a37f8d38452b8c700a72205a41bb2", "sha256": "346f797a388a852a4991a48620f7152ad4630db1d00eae3db016d50e528ffd26" }, "downloads": -1, "filename": "self_driving_desktop-0.0.7-py3.6.egg", "has_sig": false, "md5_digest": "3c6a37f8d38452b8c700a72205a41bb2", "packagetype": "bdist_egg", "python_version": "3.6", "requires_python": null, "size": 15749, "upload_time": "2019-05-11T21:58:17", "url": "https://files.pythonhosted.org/packages/26/cf/d37fee9e17a37433dbc75d08dce997619c200d10fec13b44976369eb510d/self_driving_desktop-0.0.7-py3.6.egg" }, { "comment_text": "", "digests": { "md5": "8a38997b103d8bd6dbe3282bbbd62658", "sha256": "e493106fadb0911a781a8f57081bd404f64b15a45e2912b83936467abeba6cac" }, "downloads": -1, "filename": "self-driving-desktop-0.0.7.tar.gz", "has_sig": false, "md5_digest": "8a38997b103d8bd6dbe3282bbbd62658", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8251, "upload_time": "2019-05-14T12:09:57", "url": "https://files.pythonhosted.org/packages/1e/b8/15bbd5c554ee54b4f0c8c2daaeef715aed7cbdc37ada2483dab81fa938b8/self-driving-desktop-0.0.7.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "3c6a37f8d38452b8c700a72205a41bb2", "sha256": "346f797a388a852a4991a48620f7152ad4630db1d00eae3db016d50e528ffd26" }, "downloads": -1, "filename": "self_driving_desktop-0.0.7-py3.6.egg", "has_sig": false, "md5_digest": "3c6a37f8d38452b8c700a72205a41bb2", "packagetype": "bdist_egg", "python_version": "3.6", "requires_python": null, "size": 15749, "upload_time": "2019-05-11T21:58:17", "url": "https://files.pythonhosted.org/packages/26/cf/d37fee9e17a37433dbc75d08dce997619c200d10fec13b44976369eb510d/self_driving_desktop-0.0.7-py3.6.egg" }, { "comment_text": "", "digests": { "md5": "8a38997b103d8bd6dbe3282bbbd62658", "sha256": "e493106fadb0911a781a8f57081bd404f64b15a45e2912b83936467abeba6cac" }, "downloads": -1, "filename": "self-driving-desktop-0.0.7.tar.gz", "has_sig": false, "md5_digest": "8a38997b103d8bd6dbe3282bbbd62658", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8251, "upload_time": "2019-05-14T12:09:57", "url": "https://files.pythonhosted.org/packages/1e/b8/15bbd5c554ee54b4f0c8c2daaeef715aed7cbdc37ada2483dab81fa938b8/self-driving-desktop-0.0.7.tar.gz" } ] }