<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Sebastian Szwarc on Medium]]></title>
        <description><![CDATA[Stories by Sebastian Szwarc on Medium]]></description>
        <link>https://medium.com/@Behinder?source=rss-e5814f7bb876------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*Tl6v_Nyjr7IMG-Im.jpeg</url>
            <title>Stories by Sebastian Szwarc on Medium</title>
            <link>https://medium.com/@Behinder?source=rss-e5814f7bb876------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 28 Nov 2026 09:43:06 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@Behinder/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Importing YouTube videos to Plex with Workflow and remote server]]></title>
            <link>https://medium.com/@Behinder/importing-youtube-videos-to-plex-with-workflow-and-remote-server-cd1de44bd678?source=rss-e5814f7bb876------2</link>
            <guid isPermaLink="false">https://medium.com/p/cd1de44bd678</guid>
            <category><![CDATA[plex]]></category>
            <category><![CDATA[streaming]]></category>
            <category><![CDATA[linux]]></category>
            <category><![CDATA[youtube]]></category>
            <category><![CDATA[workflow]]></category>
            <dc:creator><![CDATA[Sebastian Szwarc]]></dc:creator>
            <pubDate>Sun, 30 Dec 2018 21:48:08 GMT</pubDate>
            <atom:updated>2018-12-30T21:51:47.441Z</atom:updated>
            <content:encoded><![CDATA[<p>Inspired by Federico Viticci’s idea of using Workflow to import YouTube videos into Plex I decided to give it a try and to make it work. Because I cannot afford Mac Mini as a home server and since I still have some space on my VPS left I tried to go that route and share some remarks.</p><h3>Federico Viticci on Twitter</h3><p>From a YouTube link to a 4K video ready to watch in Plex thanks to Shortcuts, youtube-dl, and the Mac mini. Loving this setup (and will write about it after the holidays)</p><p>First, let’s create some script in Workflow app. I am still using 10.3 on my iPad and with iOS 12 Apple decided to rename the app as “Shortcuts”. I will however always refers to it as “Workflow” for several reasons. My attitude was always not to upgrade operating system to latest release if I my device is working fine. Recent years it became noticeable trend for Apple to break different things in each major release for sake of bringing something “amazing” in time for Keynote. Besides I feel the term “Shortcut” as misleading in that particular case, because for me “shortcut” means “combination of pressed keys to launch something” while workflow is “a sequence of tasks to make something done” which better represents what exactly happen and how it looks in the app.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*WaQSVI5wyN47mM-HHW6ojg.png" /></figure><p>As you can see, script is very simple. It only captures link to youtube movie and pass the name to script that is launched on remote machine by SSH action. So let’s see what needs to be done on our ‘backend’ part. Assuming you already have Plex set and running on linux machine, the only other tool you need is <strong>youtube-dl. </strong>I’m using Ubuntu so it can be installed by command sudo apt install youtube-dl but I installed it from project’s site as you may not always find recent version in repositories. Google often change something in YouTube API so it’s important to have always latest version of the tool.</p><pre>#!/bin/bash<br>args=(&quot;$@&quot;)<br>youtube-dl ${args[0]}</pre><p>My server script ytfetch.sh is also very simple. It takes video link passed from Workflow and launch youtube-dl without any additional option. Since 2016 or maybe even earlier youtube-dl default configuration is to always fetch best quality with best audio possible. When for any reason result is not what you expect than youtube-dl -F [url] lists all the available formats for video and -f allows even for separate download video and audio feed and merge them to desired format. Because I want video encoded right into my Youtube library on Plex I put one line in .config/youtube-dl/config :</p><pre>-o &#39;~/PlexLibrary/Youtube/%(title)s_%(resolution)s.%(ext)s&#39;</pre><p>These % commands are examples of templating language provided by youtube-dl and they are in fact Python extrapolated variables (for complete list of templates refer to <a href="https://github.com/rg3/youtube-dl/blob/master/README.md#output-template-examples">Github example</a>).</p><p>The one last thing to do is to ensure Plex will refresh library after adding video. It is not as simple as it may look because Plex scanner located in directory &#39;/usr/lib/plexmediaserver/Plex Media Scanner` is unfortunately user-specific and since my Plex installation is run by user ‘plex’ I couldn’t find a way to run a script from my shell as ‘plex’. To have things worse messing with LD_LIBRARY_PATH (a solution you can find on Plex forum) may broke your installed apps like vim. At the end I realised the best route is to add the line to the end of the script:</p><pre>curl &quot;<a href="http://sebastianszwarc.pl:32400/library/sections/3/refresh?force=0&amp;X-Plex-Token=QPL1zAw39HzteVWTPKKS">http://127.0.0.1:32400/library/sections/3/refresh?force=0&amp;X-Plex-Token=Y</a>OUR_PLEX_TOKEN&quot;</pre><p>You must replace “3” with id of section you want to add video to. How to get Plex Token? It is very simple. Whatever video you have in your library click “Get Info” in Plex web app as seen below and then “Show XML”. The last parametr in URL is X-Plex-Token= and string after that is what you looking for.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qK8qQII-0IThOW2qoSkx_A.png" /><figcaption>Getting info about specific video in Plex</figcaption></figure><h4>Things to improve</h4><p>I created this solution very quickly and therefore it lacks some polish or additional functionality e.g there is no support for “encoding queue”. One solution for that would be adding links to text file one in each line and put cron job for checking content of this file e.g. once in an hour and then to perform batch reencoding using -a flag.</p><h4>Why can this be useful?</h4><p>The question that should be raised now is “what for?” First idea is that <strong>youtube-dl </strong>allows going around geoblocking rules so it’s possible to download video that otherwise cannot be seen in your country. Another benefit is to have video converted to format that Plex supports natively, hence no need for transcoding — very usefull as linux VPS may lack of enough processing power. Additionaly I function in Apple ecosystem and was never attached to idea of watching on mobile devices so I prefer to use my Apple TV on regular basis. I do not own neither 4K TV set nor iPad capable of displaying 4K video (you should remember that HDR is what makes a difference not 4K) but even if I had it wouldn’t be possible to watch 4K video on YouTube. The reason for that is Google insisting every 3rd party company should use its VP9 codec — solution which Apple will never agree. So for YouTube in 4K we will be stuck with such workarounds a little longer. And remember if Plex interface seems to you a bit clunky and convoluted you may always connect to Plex servers using excellent <a href="https://itunes.apple.com/us/app/infuse-5/id1136220934?mt=8&amp;at=10lc9Y&amp;ct=medium"><strong>Infuse 5 pro </strong></a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=cd1de44bd678" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[VUDU arrives on Apple TV. Just in time]]></title>
            <link>https://medium.com/dreamer-in-black/vudu-arrives-on-apple-tv-just-in-time-5c651a64901?source=rss-e5814f7bb876------2</link>
            <guid isPermaLink="false">https://medium.com/p/5c651a64901</guid>
            <category><![CDATA[film]]></category>
            <category><![CDATA[apple]]></category>
            <category><![CDATA[vudu]]></category>
            <category><![CDATA[itunes]]></category>
            <category><![CDATA[technology]]></category>
            <dc:creator><![CDATA[Sebastian Szwarc]]></dc:creator>
            <pubDate>Tue, 22 Aug 2017 13:50:39 GMT</pubDate>
            <atom:updated>2017-08-22T13:56:00.757Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Xr37FxEtbEH2c_PoQbAx4g.png" /></figure><h3>VUDU arrives on Apple TV. Just in time…</h3><p>Right on schedule today<strong> </strong><a href="http://vudu.com/"><strong>VUDU</strong></a> finally arrived on Apple’s tvOS Store after year and a half of waiting, and this is huge. When Apple introduced its 4th generation model it received a lot of criticism for being “unprepared” product, released just to satisfy techbloggers. Initially lot of application were missing, and even if the situation improved in time, absence of major players in the house — Google, Amazon and VUDU was noticed. So today premiere is VERY important because this is the first time when Apple allows in its App Store application or service made by its direct competitor. There was never Google Play Movies on ATV (understandable) nor Spotify or SoundClud, with Pandora and iHeartRadio being notable exception in area of music streaming apps. So VUDU’s debut is a small punch in the nose of Amazon Prime that is probably scheduled to relase on 5 September.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*EUFKyxDSK2EH-x5iYs8zbQ.png" /></figure><h3>What Disney has in locker ?</h3><p>In our strange world of copyright and licensing deals a movie is no longer just DVD/Blu-Ray but a file stored in the cloud. So new problem arises — how to manage all of this? And of course there are no simple solution to that problem because movie industry is same divided as ever before. Smaller studios founded UltraViolet consortium, while big players like Amazon,Google and Disney decided not to participate. The latter is notable case here, becasue Disney develops own solution called <strong>KeyChest</strong> that is base of Disney Movies Anywhere service. Taking into account close relations of Disney with Apple, no wonder that iTunes was first service to allow connect Apple ID with DMA login, giving ability to watch Disney movies bought from various sources right in iTunes.</p><p>UltraViolet however is still a bit messy with lot of content providers. Technically, myuv.com was supposed to be you all-in-one locker but in practice this is not so simple. I can add titles I got from VUDU to see them in FandangoNow account but for now there is no way in VUDU to see my “Sharknado” from FN. To have thing worse, this whole VUDU experience on mobile devices was far from perfect, forcing people to use AirPlay and with weak connection HDX quality was far from expected.</p><p>Despite this problems, there is still noticeable trend in USA for attaching UltraViolet codes to physical copies, not the one from iTunes. And because VUDU aims to be your best friend in UV garden, lack of ATV support put Apple device in certain disadvantage to major competitors like Roku, Chromecast and FireTV, until now.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*__c5UKMPH4OFGpgSPZ2h2Q.png" /></figure><p>What about the app? As predicted VUDU doesn’t want to give Apple its cut, so you are only able to watch previously purchased or rented movies. With one small sort of exception — “Movies on US” section. This is selection of titles available for free to stream with ads. So technically it’s not a rent or purchase and I suppose this addition will be warmly welcomed for any cordcutter who doesn’t know what to watch friday evening. The same applies to TV Shows — maybe they are not first of the league titles but still it’s a good place to find something new.</p><h3>What’s next?</h3><p>It’s good to see bunch of Apple TV related news ahead of Keynote, where we see predicted 5th generation of the box with HDR and 4K support. I’ve mention 5 of September as my predicted day of Apple event. It’s the best possible date because NFL starts on September 7th with Kickoff game and<br> during this season it’s first time when Amazon bought broadcasting rights to 10 games for streaming in Prime as Thursday Night Football. It’s obvious they want focus people’s attention on their tvOS debut and what moment is better than Keynote?</p><p><em>You may read polish version of this article on </em><a href="https://mojmac.pl/2017/08/22/vudu-debiutuje-na-apple-tv-co-to-oznacza/"><em>Mój Mac</em></a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5c651a64901" width="1" height="1" alt=""><hr><p><a href="https://medium.com/dreamer-in-black/vudu-arrives-on-apple-tv-just-in-time-5c651a64901">VUDU arrives on Apple TV. Just in time</a> was originally published in <a href="https://medium.com/dreamer-in-black">Dreamer In Black</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Creating Netflix cover photo with Workflow]]></title>
            <link>https://medium.com/dreamer-in-black/creating-netflix-cover-photo-with-workflow-af95709379b4?source=rss-e5814f7bb876------2</link>
            <guid isPermaLink="false">https://medium.com/p/af95709379b4</guid>
            <category><![CDATA[workflow]]></category>
            <category><![CDATA[automation]]></category>
            <category><![CDATA[apple]]></category>
            <category><![CDATA[netflix]]></category>
            <category><![CDATA[programming]]></category>
            <dc:creator><![CDATA[Sebastian Szwarc]]></dc:creator>
            <pubDate>Sat, 22 Apr 2017 22:37:45 GMT</pubDate>
            <atom:updated>2017-05-03T19:18:18.646Z</atom:updated>
            <content:encoded><![CDATA[<h3>How to create Netflix cover photo with Workflow</h3><p>Workflow is a wonderfull iOS application that can simplify tedious jobs by allowing you to create usefull macros. These macros are build from simple one-task Actions that you can freely chain together, much like you could do on MacOS using Automator. Recently I found one use case regarding my blogging activity that I want to share with you. I blog about movies,and even if my activity in this field is dormant at best, currently I started posting what new titles arrived on polish Netflix in a week. It’s part of a larger project in which I share such info on Twitter and by RSS feed. So I decided that as illustration of such blog post it’s good idea to have one big image containing posters of all newly added movies to Netflix in Poland.</p><h4>Few words about Content Graph</h4><p>Workflow macros are build from pieces called <strong>Actions</strong>. They are basically two kind of actions — one-directional or pass-thru. The former example is “Number” action that allows only output flow (usually to perform some calculation or to set a variable) and even if you build some input to it, it will not have any effect. The latter can accept input and produce output, <strong>“Combine Images”</strong> action being notable example here — it will accept several images at input and release combined image as a result. <br>What is brilliant with this approach is all the actions are very intelligent. For every input element each action creates virtual graph that connects different types of data together. To clear things a bit imagine that we want convert image for text — how can this be possible? It’s simple — we got its URL in return. If we add several lines of text to a variable they will be treated as elements of a “list” (it’s a Workflow designation for an array) etc. <br>That approach may seem tricky at first, but when we are carefull it allows us to perform very versatile operations.</p><h4>How to get data from Netflix</h4><p>To avoid unnecessary scraping I used a UnoGS API — it’s unofficial gateway to all intresting Netflix data, updated on daily basis. When Workflow added support in version 1.7 for POST and GET method for any URL, access to all sort of REST APIs was finally possible. So what we do is to perform request to proper API URL and to get JSON object (luckily it is interpreted by Workflow as ‘Dictionary’) and store it as variable. The first problem I encountered here is two-dimensional array are not supported in Workflow and I got one big list of elements instead. Because there is exactly 13 elements in response object, this is a number we need index shift to.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*PLGdcfmUv2jNbftROSoZxg.jpeg" /></figure><p>As you can see on picture above the procedure to retrieve all images is as follows:<br>* Get item from the list at index 3 <br>* Get URL object from the string <br>* Get Image from the URL -&gt; it downloads image to memory <br>* Append it to variable -&gt; we essentialy creates here an array of image objects for further use.<br>* Shift index 13 places<br>* Repeat process</p><p>Now we have two possibilites either automatic grid creation or touching the process a bit by hand.</p><h4>Variant no. 1 — Using auto-grid</h4><p>The built-in action “Combine Images” is surprisingly intelligent and it’s able to work in grid mode with user defined ‘spacing’ parameter.</p><figure><img alt="" src="https://cdn-images-1.medium.com/proxy/1*mTDg6B7e2HMVZ74sEzofzg.jpeg" /></figure><p>And the result of operation:</p><figure><img alt="" src="https://cdn-images-1.medium.com/proxy/1*n8BCzYB1IUk2fLUuB8Ns5Q.png" /></figure><h4>Variant no. 2 — manual grid</h4><p>This was a bit tricky for a moment, but it’s easier if you do some math in head and decide how many rows you need to create rectangular cover. Doing quick math result in formula: <br><em>NumberOfImages/NumberOfRows= RoundUp(NumberOfPicsInRow)</em><br>This time situation is more difficult because we need to shift two indexes that mark beginning &amp; end of range.</p><figure><img alt="" src="https://cdn-images-1.medium.com/proxy/1*DiGhJJ3BiP1eMXsT1BVDdw.png" /></figure><p>The macro above do few things:<br>* get number of images from the list <br>* increase both indexes on the number corresponding to number of images in row <br>* add resulting image to ‘Rowgrid’ variable that stores rows of posters <br>* To avoid ‘index out of bounds’ error we check if end index is greater than number of images. <br>Therefore we allow situation when last row may not be filled completely with posters.</p><p>It’s worth noting that we still didn’t get our cover, just array of images. Fortunately there is no need to ‘Repeat’ action because putting <strong>“Combine Images”</strong> right after <strong>“Get Variable — Rowgrid”</strong> combine each of the element ino beautifull cover art. The result is seen below:</p><figure><img alt="" src="https://cdn-images-1.medium.com/proxy/1*om9V3DPnHTlPRUltIZABJw.png" /></figure><h4>Conclusion</h4><p>Taking this challenge was great fun to me and I learned a lot. As you can see Workflow is superb application that can make tedious job a breeze. Although such kind of task requires lot of fiddling and moving actions because Workflow still doesn’t have good engine for debugging,once it’s set up it works like a charm. It’s clearly seen that even Apple recognized power of this app by its recent aquisition. <a href="https://www.macstories.net/stories/the-future-of-workflow/">The future of Workflow</a> is now at least uncertain, but for now it’s still works and I encourage everyone to try such kind of graphical programming.</p><p><a href="https://itunes.apple.com/pl/app/workflow-powerful-automation-made-simple/id915249334?mt=8&amp;uo=4&amp;at=10lc9Y">Get Workflow (iOS)</a> (Free)</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=af95709379b4" width="1" height="1" alt=""><hr><p><a href="https://medium.com/dreamer-in-black/creating-netflix-cover-photo-with-workflow-af95709379b4">Creating Netflix cover photo with Workflow</a> was originally published in <a href="https://medium.com/dreamer-in-black">Dreamer In Black</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[7 things I remembered after Apple WWDC Keynote]]></title>
            <link>https://medium.com/dreamer-in-black/7-things-i-remembered-after-apple-wwdc-keynote-5dbbf160535e?source=rss-e5814f7bb876------2</link>
            <guid isPermaLink="false">https://medium.com/p/5dbbf160535e</guid>
            <category><![CDATA[macos]]></category>
            <category><![CDATA[apple]]></category>
            <category><![CDATA[apple-tv]]></category>
            <category><![CDATA[wwdc]]></category>
            <category><![CDATA[tvos]]></category>
            <dc:creator><![CDATA[Sebastian Szwarc]]></dc:creator>
            <pubDate>Thu, 16 Jun 2016 12:59:38 GMT</pubDate>
            <atom:updated>2017-05-21T18:25:20.284Z</atom:updated>
            <content:encoded><![CDATA[<p>WWDC 2016 has started and will last during this week and it was as always started by 2-hour long Keynote. This year there was lot of topics to cover and therefore my impression that it could easily lasts another hour and probably nobody would ever notice it. Before my brain will explode from data overloading here are some important things for notice, written from perspective of non-US Apple user.</p><h4>#1 Apple News overhauled but still only for english speaking countries</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*HzSrcCXkHyYx-n3OXXodIw.jpeg" /></figure><p>There was lot of doubt last year, when Apple introduced News essentialy making their Newsstand obsolete. However, for most of us blogers and tech journalists from countries like Poland this was not painless transition. Newsstand dissapeared but we didn’t get anything in return. We’ve tried to add our blogs to Apple News but there was not accepted because…our language was not supported. Today Apple introduced overhauled interface to Apple News together with new subscription system from which lot of publishers will benefit soon, but again — what is the reason to reinvent RSS with limiting the service to just one language?</p><h4>#2 Hey Siri,welcome to Mac but when do you start speaking my language?</h4><p>As it was predicted Apple’s personal assistant will get its macOS counterpart. New iteration of Siri is supposed to be smarter and able to do more stuff. But from first look, Siri’s ability on Mac is pretty basic but we should expect improvements till official release in Autumn. The biggest question here is perhaps if we see new languages added to the mix. Of course there is still no support for Polish language and probably never will be which leaves me in very dissapointed state. It’s not only matter of communication with the phone — Siri’s engine powers up lot of other proactive functions e.g. in Spotlight. Therefore, without my language supported It doesn’t look smart to be early adopter on macOS Sierra :(</p><h4>#3 Apple Music redesign</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*OsMxeH2JJqZLJI5akjhKTw.jpeg" /></figure><p>Apples own music streaming service will get overhaul. It’s not particulary surprising move because Music interface has been constantly repaired since its debiut in July 2015. It’s still has some caveats, for example:</p><ul><li>do I really need to turn iCloud Music Library to create playlist?</li><li>allegedly, there is no proper fingerprinting for recognizing tracks, a flaw that may give you surprising effect when you delete music you own and count on iCloud backup.</li><li>“For you” section still (at least in my case) not give relevant results for my tase offering instead lot of “introduction to…” playlist for artis I really know well.</li></ul><p>There was no mention of Beats 2 stations, which is dissapointing a bit because Beats 1 in my impression offers music more suitable to younger generation than such old fellow as me ;) However, intresting ommission is Connect. Does it mean Connect will follow its Ping precedessor and cease to exist?</p><h4>#4 Apple Pay in web way</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*hpYvuTfIczPaFq96o3pQDQ.jpeg" /></figure><p>Apple Pay will get it’s web counterpart..sort of. New framework will allow sellers to put relevant buttons on their stores to initiate transaction, however that transaction still needs to be finished on your iPhone. Sounds great but again..there are only few countries with Apple Pay with only three more soon to follow. And again..no Poland, which it’s kinda surprising because we have lot better credit card infrastructure than in US. With such speed I expect Apple Pay to enter Poland in 2020–2025. How the e-market world will look then, only God knows.</p><h4>#5 Universal sign-in in tvOS</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*c-pHCQ6cBXjdOtBfn_FYHg.png" /></figure><p>This detail really focused my attention, because it’s example of great feature of which we have no clue how this even going to work. Apple TV was always American (and a bit British) device meaning that only US-based broadcasters understand power of such device or the other part of the world do not have enough skilled engineers to design such service. So there is no mistake in fact that this ancient app-activation technique using letter-digit code that needs to be enter on mobile device or on desktop was mainly used by US channels like ABC, FOX, CW or NBC. This utilized “TV everywhere” solution that allows cable operators to provide access to apps’ content by user cable tv credentials. It isn’t and never was an ideal solutions especially for cord-cutters but still better service than in most non-US countries. Now Apple wants to relieve us from pain of regular activation offering instead universal “one sign-in” solution. However, there are still some question that needs to be answered. Will this be separate service or only overlay for current validation methods? How this will work outside USA? What if I have cable subscription without sport package and my friend visit me at home and want temporarily login to his cable operator to watch Opening Game of NFL season? Is this technology helps fight with unauthorized access from stolen accounts? Or maybe Apple will build solution for themselves, which is not impossible regarding current rumours about aquiring Time Warner soon? Again, time will tell.</p><h4>#6 Universal clipboard and AFS!</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*n7P70bTNmripxvuFV1kVcg.jpeg" /></figure><p>Many people that follow Keynote will often forget to watch “Platform State of the Union” lecture the same day. Huge mistake! Communication between iOS and OSX devices was always a bit problematic. Many users relied on Dropbox, then iCloud drive saw the sunlight but still there was no perfect solution and 3rd party developers like <a href="https://geo.itunes.apple.com/pl/app/deskconnect/id642218244?mt=8&amp;at=10lc9Y&amp;ct=medium">Desk Connect</a> trying to fill the gaps. And now Apple not only found remedy for these problems but also introduced new Apple File System. This is huge thing because last time such thing happened back in 1998, in those ancient times when floppy disk was still in use as well as mechanical hard drives. Today times are different and AFS aims to replace HFS+ in devices where main storage is flash/SSD based. AFS will also offer native encryption, thing that certainly not make FBI and CIA happy. There are of course still question that needs to be answered: Are this gonna work only between iOS10 and macOS Sierra devices? Does Sierra needs to be installed on clean fresh drive formatted with AFS to take benefit of these new features? For now, macOS Sierra Developer Preview can be installed on HFS+ formatted drive but this may change before Autumn.</p><h4>#7 War against Google began…</h4><p>There was one thought that appeared immediately few times during 2 hours presentation — “What will Google do?”. I have no sympathy for Android devices and this is not going to change, but remember Google earns lot of his money from Ads. Apple shut down theirs iAd program so developers needs to rely on Google AdSense. But during Keynote Apple has shown us at least two situation that allows end user to ommit Google Ads. First, Siri being able to search internet for images and provides relevant results in its own window and second — Picture in Picture that finally arrives on Mac. Since its introduction on iOS9 more and more applications that serve video content added ability to watch it in PiP mode, but Google was never among them, so again 3rd party solution like <a href="https://geo.itunes.apple.com/pl/app/youplayer-video-player-for/id561921453?mt=8&amp;at=10lc9Y&amp;ct=medium">YouPlayer</a> emerged. With their Maps constantly improving and with such additions to macOS Apple may really try to cut Google incomes a bit and allow users to get information they want without seeing Google.com.</p><p>WWDC is always most intresting Apple event in year, if you want to know more don’t forget to follow conference schedule in Safari or in apps both for <a href="https://geo.itunes.apple.com/pl/app/wwdc/id640199958?mt=8&amp;at=10lc9Y&amp;ct=medium">iOS</a> and tvOS.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5dbbf160535e" width="1" height="1" alt=""><hr><p><a href="https://medium.com/dreamer-in-black/7-things-i-remembered-after-apple-wwdc-keynote-5dbbf160535e">7 things I remembered after Apple WWDC Keynote</a> was originally published in <a href="https://medium.com/dreamer-in-black">Dreamer In Black</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Using Workflow for export Spotify playlist to Apple Music]]></title>
            <link>https://medium.com/dreamer-in-black/using-workflow-for-export-spotify-playlist-to-apple-music-729af5d7711f?source=rss-e5814f7bb876------2</link>
            <guid isPermaLink="false">https://medium.com/p/729af5d7711f</guid>
            <category><![CDATA[automation]]></category>
            <category><![CDATA[workflow]]></category>
            <category><![CDATA[apple-music]]></category>
            <dc:creator><![CDATA[Sebastian Szwarc]]></dc:creator>
            <pubDate>Sat, 04 Jun 2016 20:31:58 GMT</pubDate>
            <atom:updated>2018-07-21T10:14:39.318Z</atom:updated>
            <content:encoded><![CDATA[<p><strong>[Update 21.07.2018]</strong><em> I rewrite not-working workflows and modified links accordingly.They should also work in iOS12 even after Shortcuts introduction. Also added missing link to IFTTT receipe and third workflow to import whole playlist from Safari URL.</em></p><p>It’s almost a year since Apple introduced its streaming service. Initially I welcomed it with hope but soon after had a lot of mixed feelings. Inconsistencies in UI and weird engine choices (“Why I cannot add song to a playlist without turning iCloud Music Library first?”) only increased that attitude. To make things worse Apple haven’t provided no sort of API for 3rd party developers, a move that create great question for all of music lovers — “How the hell I am gonna transfer my Spotify playlist?”</p><p>This quickly become non-trivial issue that caused frustration both on average user and developer side. Some solution emerged — <a href="https://geo.itunes.apple.com/us/app/stamp-music-imporer/id1088699621?mt&amp;at=810lc9Y&amp;ct=medium"><strong>Stamp</strong></a><strong> </strong>being notable example — but they were at least hacky or non-elegant ways that utilized e.g. AppleScript to automate boring and tedious job. Fortunately, things are getting better when Apple finally relased some sort of API and with recent 1.5 update of <a href="https://geo.itunes.apple.com/pl/app/workflow-powerful-automation/id915249334?mt=8&amp;at=10lc9Y&amp;ct=medium"><strong>Workflow app</strong></a> that introduced some iTunes/Apple Music action added to its core. For those of you unaware of what exactly Workflow is short explanation — it’s one of the best apps on iOS market allowing user to automate stuff using several draggable actions and chaining them together. So when my twitter friend Marta(<a href="http://twitter.com/martystka">@martystka)</a> shared to me some nice tunes on YouTube I started to think how to automate import process and began to fiddle with Workflow actions.</p><h4>First attempt — save single track</h4><p>If you get link to any song in Spotify and try to open it in browser you will end in something like this:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*e6kFJV3rJy4-NeuuP7xrsA.jpeg" /></figure><p>Because we are in Safari, our workflow can be run as action extension and with this approach fortunately we can use <strong>“Get Details of Safari Web Page”</strong> and choose “Name” as an option. After that following steps are done:</p><ol><li>“on Spotify” is removed from string</li><li>Artist and title of the song are matched from string using regexp and saved as separate groups</li><li>Groups are extracted from matched text and saved to variables</li><li>Search iTunes Store for songs using [Artist] [Title] criteria and return only 1 relevant result.</li><li>If result is not empty add it to playlist — in my case I called it “Spotify”</li></ol><p>You may grab this workflow <a href="https://workflow.is/workflows/a900f5f29d294466a9317f4df4d717e1"><strong>here</strong></a><strong> </strong>(change iTunes country approprietly)</p><h4>Second attempt — batch link processing</h4><p>If we have small playlist method above may work but it’s time consuming. And what when our playlist contains dozens or even hundreds of tracks? Different approach is needed. But again things become harder on iOS client that offers no way to select multi tracks in single playlist and what I wanted is to keep things as simple as possible and avoid advanced scripting in <a href="https://geo.itunes.apple.com/pl/app/pythonista/id528579881?mt=8&amp;at=10lc9Y&amp;ct=medium"><strong>Pythonista</strong></a><strong>. </strong>So it’s better to start on desktop client, go to any playlist we need to transfer and select all the tracks by CMD-A (CTRL-A on Windows) and copy-paste it to text file in place where we have access to from our iPhone/iPad. Dropbox seems to be simple solution for the job, remember only to add “txt” extension to file otherwise it may not be visible by apps like Drafts. And this is another moment when things get complicated. Because we have to batch process bunch of links we cannot use Workflow as extension and therefore “Get details of Safari Web Page” is not available. Name of the actions can be little confusing, so by trial and error I figured that “Get details of Articles” is unnessecary and I should use “Get URL’s from input” — “Get contents of URL” — “Get text from input” combo. So this time procedure will include additional steps:</p><ol><li>Every track link needs to be in separate line in clipboard</li><li>We need to split clipboard content into separate lines, every line assigned to variable.</li><li>Because this time variable will hold multi-line string I need to find correct pattern to match artist and title using regular expressions.</li><li>There is additional variable called <strong>PublishedBy, </strong>that holds translation for “published by”, you should modify it according to your needs.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pOs6dzpJlJdHbqqUQNTbjg.png" /></figure><p>Of course with large number of track in playlist you must be patient and let Workflow do this job, but after all that’s why computers are for :) You can grab this script <a href="https://workflow.is/workflows/7c2db3e910c54ef890e1593136373268"><strong>here</strong></a><strong>. </strong>Workflow in action is presented in movie below:</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FT_KJEpMlZAM%3Ffeature%3Doembed&amp;url=http%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DT_KJEpMlZAM&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FT_KJEpMlZAM%2Fhqdefault.jpg&amp;key=d04bfffea46d4aeda930ec88cc64b87c&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/481392395642de366b58c8d92045ce11/href">https://medium.com/media/481392395642de366b58c8d92045ce11/href</a></iframe><h4>Third attempt — import whole single Spotify playlist</h4><p>This time I’m running workflow from extension because what we need frst is to open playlist’s URL in Safari. Workflow identify playlist from ID in URL and starts to extracting artists and song names in a loop matching them to iTunes counterparts. You may grab this workflow <a href="https://workflow.is/workflows/7360cae5fcaa4e1296d13a311e7aee52"><strong>here</strong></a><strong> </strong>— this is modified version after several talks with Workflow developers, who found that HTTP2 protocol not working well with Spotify API, hence the ‘Upgrade’=&gt;’TLS/1.2&#39; in each header of Spotfy API call.</p><p>I’ve started to use Spotify lately again, mainly because of its wonderfull “Discover Weekly” feature which (suprisingly) I find a lot better than Apple Music’s <strong>“For You”. </strong>With this <a href="https://ifttt.com/applets/37790261d-discover-weekly-archive">IFTTT receipe</a>, every Monday new text file will be created in Dropbox and it will include URL of every track in that playlist so with this workaround you may have best of both worlds. I hope this helps someone and encourage you to your own experiments with automation :)</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=729af5d7711f" width="1" height="1" alt=""><hr><p><a href="https://medium.com/dreamer-in-black/using-workflow-for-export-spotify-playlist-to-apple-music-729af5d7711f">Using Workflow for export Spotify playlist to Apple Music</a> was originally published in <a href="https://medium.com/dreamer-in-black">Dreamer In Black</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>