Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # -*- coding: utf-8 -*-
- from click import group, argument
- from ScriptingBridge import SBApplication
- @group()
- def main():
- pass
- @main.command()
- @argument('name')
- def sync(name):
- itunes = SBApplication.applicationWithBundleIdentifier_("com.apple.iTunes")
- for src in itunes.sources():
- if src.name() == name:
- src.update()
- if __name__ == '__main__':
- main()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement