Your Web News in One Place

Help Webnuz

Referal links:

Sign up for GreenGeeks web hosting
May 20, 2021 01:09 pm GMT

Community showcase: automated home setup to stay in flow

Code Time, Softwares extension for code editors and IDEs, helps you protect valuable code time with Flow Modea set of automations that makes it easy to eliminate distractions, mute notifications, and stay focused when youre in flow.

Once connected to a Slack workspace, Flow Mode enables Slacks Do Not Disturb mode, sets a custom status message, and adds a purple icon to your status. In some editors and IDEs, like Visual Studio Code, you can also choose to enable Zen mode or enter fullscreen with Flow Mode. Flow Mode can be triggered manually, via a button in the sidebar or status bar, or automatically, based on your coding activity.

Shane Lawrence, a member of the Software community and senior software developer, saw an opportunity to make Flow Mode even more powerful.

He extended Flow Mode to automate his entire workspace setup:

  • Change ambient lighting in his workspace to purple
  • Silence notifications on his phone
  • Set a custom Do Not Disturb status on his home system

Heres a short demo of Shanes custom Flow Mode in action:

Overview of the flow automation stack

Shanes setup uses a few different automation tools and APIs:

Shane wrote a small watcher script in Node.js that checks for changes to his Slack status using the Slack Events API (@slack/events-api). If a new status includes Flow Modes purple emoji, , Shanes bot sends a custom begin_flow or end_flow event to his Home Assistant, a popular open source home automation hub.

Home Assistant then sets a custom Do Not Disturb mode for his home automation system, triggers his workspace lighting, and sends a notification to his phone.

Home Assistant comes with powerful connections out-of-the-box. It integrates directly with Philips smart bulbs and Nanoleaf lights, as well as more than 1,500 other smart devices. To control his phone, Shane uses AutoRemote to listen for notifications from Home Assistant. Tasker then changes his phones settings.

In his next iteration, Shane is considering how he might trigger Digital Wellbeings Focus Mode to disable all distracting apps on his Android phone. He is also exploring how he could integrate with Spotify to start playing newly recommended songs from Music Time when hes in flow.

Why defending flow matters

Developers constantly battle meetings, interrupts, and inertiathe enemies of developer flowthat interfere with valuable code time. Impromptu Zoom calls and relentless Slack messages make work feel disjointed and chaotic.

Protecting flow helps us silence these distractions and make the most of each workday. From Shane:

As someone whos deeply passionate about the work I do, being in flow is the part of my day where Im immersed and energized in what I really love most: working on challenging problems and helping online communities be a safer place for everyone to connect.

While Im fortunate to have been able to keep my job through the pandemic, working from home has introduced its own set of challenges, such as staying focused on days when other distractions want to drag my attention away from important tasks, making it difficult to always sink my teeth into a solid coding session.

Code Times flow feature combined with my smart home integration helps me quickly tune out all of the distractions at once, helping me focus faster and reduce the chatter of apps and chat messages all competing for my attention.

If youre interested in automation tech, you can find Shane on Twitch, where hes currently building a bot service that helps streamers let their viewers redeem channel points to change their smart light colors. He streams Wednesdays at 6pm PT and Saturdays at 7pm PT. Shanes streams are open to all, coders and non-coders alike.


Original Link: https://dev.to/softwaredotcom/community-showcase-automated-home-setup-to-stay-in-flow-37f

Share this article:    Share on Facebook
View Full Article

Dev To

An online community for sharing and discovering great ideas, having debates, and making friends

More About this Source Visit Dev To