Scott Hanselman

You're tired because your lizard brain knows that Zoom meetings aren't natural

June 25, '20 Comments [12] Posted in Musings
Sponsored By

Remote work isn't normal. It's great when it's not quarantine work, to be clear. I've worked remotely with success for over 13 years and written about it extensively. I'm pro-remote work. But.

Doing zoom calls all day can be super productive but they are also physically and emotionally exhausting. One of the reasons that isn't helping you is that a zoom meeting isn't a natural human state - it's a simulation of one and your body knows the truth.

I'm using "Zoom" the brand here as a pervasive generic verb like folks use Kleenex for tissue or Google for any websearch. I zoom with Teams and google with Bing, for example. You get the idea.

So what do I mean when I say "remote work isn't normal?" Why such a declarative statement? Because I'd propose that our lizard brains know that we're talking to ourselves, alone in a room.

"The brain stem, the cerebellum, and the basal ganglia – commonly known as “the lizard brain” because it’s the part we inherited from our reptilian predecessors – are responsible for fight or flight responses, fear, suspicion, and anxiety. The lizard brain kept our ancestors safe when a panther pounced from a limb just overhead. In an ironic twist, these most ancient parts of the brain are making it difficult for us to think rationally at a time when rational thought is key to our survival." - Courier Journal

Your body knows the people aren't there. Their electricity isn't in the room with you. They are flat. All their voices come from one point in space, not from all over the room. There is no sense of space. Even worse if you have headphones. They are 3 inch tall tiny talking heads while their voices are 1 inch from your ears. There's a strange detached intimacy where you're both closely connected to the group virtually while utterly disengaged physically.

Teams and Zoom calls aren't natural

A Brady Bunch grid of faces is not what the brain expects when you're having a meeting, so we're constantly fighting against the cognitive dissonance, the background process load, the psychic weight, that we ARE in the same room talking with our co-workers.

Your conscious brain says you're having a chat in a room with a dozen of your co-workers but the unconscious brain says you're not. It's small but I'd propose it's there. Doing this for hours and hours can give you the same kind of unease that you get from flying in a plane. You get off the plane and you're exhausted from sitting. Sure there's humidity and oxygen issues but there's also the "you know you're moving but parts of your brain disagrees" cognitive load that can't be ignored.

Remote video group calls are an amazing enabling technology but it's also enabling to acknowledge that they can be draining. That simple acknowledgement - huh, that's a thing! - is itself empowering. If you name it you can claim it. It's not just you!


Sponsor: Upgrade from file systems and SQLite to Actian Zen Edge Data Management. Higher Performance, Scalable, Secure, Embeddable in most any programming language, OS, on 64-bit ARM/Intel Platform.

About Scott

Scott Hanselman is a former professor, former Chief Architect in finance, now speaker, consultant, father, diabetic, and Microsoft employee. He is a failed stand-up comic, a cornrower, and a book author.

facebook twitter subscribe
About   Newsletter
Sponsored By
Hosting By
Dedicated Windows Server Hosting by SherWeb

Using the Blockly visual programming editor to call a .NET Core WebAPI

June 23, '20 Comments [7] Posted in ASP.NET | ASP.NET Web API | Open Source
Sponsored By

I like to showcase interesting and cool open source projects that need more attention! Go give our friend a star on GitHub! NetCoreBlockly on GitHub is clever and fun!

Blockly is a JavaScript library for building visual programming editors. If you've used languages like Scratch you've seen block-style programming environments. The picture below shows you a demo of calling a .NET Core WebAPI using Blockly code!

Remember that once you have a WebAPI you can make it available in a number of ways. The "projection" of the methods that the WebAPI makes available can be presented visually, as Swagger/OData/GraphQL, however you like. Another project is WebAPI2CLI that lets you call WebAPI endpoints easily from a CLI (Command Line Interface) that is more high fidelity than curl or wget.

.NET Core as a Blockly Editor

What .NET Core Blockly is doing is looking at the projection/interface of your WebAPI and generating Blockly blocks! That means that anyone (business users, student, tester, whatever) could try out your WebAPI with a simple drag and drop interface in their browser!

You can pull in Swagger, OData, or GraphQL interfaces.

I love seeing fun projects like this that make the web (and .NET code) easier to use! Go give them some stars and get involved!


Sponsor: Upgrade from file systems and SQLite to Actian Zen Edge Data Management. Higher Performance, Scalable, Secure, Embeddable in most any programming language, OS, on 64-bit ARM/Intel Platform.

About Scott

Scott Hanselman is a former professor, former Chief Architect in finance, now speaker, consultant, father, diabetic, and Microsoft employee. He is a failed stand-up comic, a cornrower, and a book author.

facebook twitter subscribe
About   Newsletter
Sponsored By
Hosting By
Dedicated Windows Server Hosting by SherWeb

The Importance of Nesting when Remote Working and Quarantine Working

June 11, '20 Comments [9] Posted in Musings
Sponsored By

"08.30.10" by colemama is licensed under CC BY-NC-SA 2.0.We've all learned the hard way that Quarantine work is not Remote work. It doesn't feel the same because it's not the same. It's a hard time right now and tension is high.

"People are overwhelmed, afraid, and stressed. There's a background pressure - a psychic weight or stress - that is different in these times. This isn't a problem you can fix with a new webcam or a podcasting mic."

I really believe that self-care is important and one should be as deliberate as one can in how they live.

One day we were working in the office and the next day we were home indefinitely. Some in spare bedrooms, most in our kitchens, laundry rooms, garages and front porches.

What does "nesting" mean?

Nesting is not just what a bird does to prepare their space for the coming family, it's also what we can do as humans to make a space for ourselves to be successful. It's the deliberate practice of setting up your work area so that you can be successful and fulfilled.

Your space doesn't need to be fancy. Nesting isn't blinging your space or making it look expensive - nesting is making it YOURS.

  • Can you sit and work comfortably? Is your space ergonomic as it can be?
    • Is your monitor or laptop angled in a way that doesn't cause eyestrain or neck strain?
  • Do the things around you feed your spirit? Toys? Gadgets? Family pics? Post-It Notes?
    • Be intentional. Don't just let your space happen. What is calming for you? What's productive? Do you like a nice whiteboard?
    • Perhaps a fresh notebook can de-stress you? Your office can be a Zen garden. Does clutter calm? Fill it with fun. Do you like open space? Clear your desk.
  • What's your lighting situation?
    • Do you have natural light or a window nearby? Maybe you should.

Stop for a second. Perhaps while reading this blog post. Look around and ask yourself - why is this space like this? How did it get this way and do I feel good here. What can you do? Maybe it's just straightening up. Perhaps literally just turning another direction to adjust light.

This is the start of a process to make your space you own. You can't control your quarantine situation but you can be intentional about your nest.

What have YOU done to make your space your own? How are you nesting?


Sponsor: Have you tried developing in Rider yet? This fast and feature-rich cross-platform IDE improves your code for .NET, ASP.NET, .NET Core, Xamarin, and Unity applications on Windows, Mac, and Linux.

About Scott

Scott Hanselman is a former professor, former Chief Architect in finance, now speaker, consultant, father, diabetic, and Microsoft employee. He is a failed stand-up comic, a cornrower, and a book author.

facebook twitter subscribe
About   Newsletter
Sponsored By
Hosting By
Dedicated Windows Server Hosting by SherWeb

Easily rename your Git default branch from master to main

June 8, '20 Comments [38] Posted in Open Source
Sponsored By

The Internet Engineering Task Force (IETF) points out that "Master-slave is an oppressive metaphor that will and should never become fully detached from history" as well as "In addition to being inappropriate and arcane, the master-slave metaphor is both technically and historically inaccurate." There's lots of more accurate options depending on context and it costs me nothing to change my vocabulary, especially if it is one less little speed bump to getting a new person excited about tech.

You might say, "I'm all for not using master in master-slave technical relationships, but this is clearly an instance of master-copy, not master-slave" but that may not be the case. Turns out the original usage of master in Git very likely came from another version control system (BitKeeper) that explicitly had a notion of slave branches.

Regardless, I've dozens of git repositories that have 'master' as the main branch. Changing that would be a hassle right?

image

Let's see. I'll just "git branch -m master main" and then push it back! Remember that -m is --move so your history isn't changed! Even better I can "git push -u origin main" to set the upstream at the same time.

D:\github\WindowsTerminalHere [master]
> git branch -m master main
D:\github\WindowsTerminalHere [main]
> git push -u origin main
Total 0 (delta 0), reused 0 (delta 0)
remote:
remote: Create a pull request for 'main' on GitHub by visiting:
remote: https://github.com/shanselman/WindowsTerminalHere/pull/new/main
remote:
To https://github.com/shanselman/WindowsTerminalHere.git
* [new branch] HEAD -> main

That was easy.

NOTE: Changing the default branch to "main" also has the benefit of starting with "ma" so that autocomplete <TAB> muscle memory still works. Another great option for your main github branch is "latest." The goal is to just be unambiguous.

Now I just need to change my default branch in my GitHub settings for my repository.

image

I can also update the tracking branch manually as seen here, but if you use git push -u origin main it'll do both.

git branch -u origin/main main

The last thing to think about is if you have a CI/CD, GitHub Action, Azure DevOps pipeline or some other build system that pulls a specific branch. You'll just change that to main. However, usually unless your CI explicitly calls for a branch by name, changing master to main will "just work!"

NOTE: For more complex repos also check your protected branch rules.

image

This is because -m is --move and all your reflog is unchanged!

TL;DR in conclusion:

git branch -m master main
git push -u origin main

Updating local clones

If someone has a local clone, then can update their locals like this:

$ git checkout master
$ git branch -m master main
$ git fetch
$ git branch --unset-upstream
$ git branch -u origin/main
$ git symbolic-ref refs/remotes/origin/HEAD refs/remotes/origin/main

From the tweet above (Thanks Brad from XUnit.net!), these steps

  1. Go to the master branch
  2. Rename master to main locally
  3. Get the latest commits from the server
  4. Remove the link to origin/master
  5. Add a link to origin/main
  6. Update the default branch to be origin/main

You can add an alias "git new" that will default to whatever starting branch you like.

git config --global alias.new '!git init && git symbolic-ref HEAD refs/heads/main'

Hope this helps! Other good names are latest, trunk, and stable!


Sponsor: Have you tried developing in Rider yet? This fast and feature-rich cross-platform IDE improves your code for .NET, ASP.NET, .NET Core, Xamarin, and Unity applications on Windows, Mac, and Linux.

About Scott

Scott Hanselman is a former professor, former Chief Architect in finance, now speaker, consultant, father, diabetic, and Microsoft employee. He is a failed stand-up comic, a cornrower, and a book author.

facebook twitter subscribe
About   Newsletter
Sponsored By
Hosting By
Dedicated Windows Server Hosting by SherWeb

Mirroring your Presence Status from the Microsoft Graph in Teams to LIFX or Hue bias lighting

May 21, '20 Comments [4] Posted in Open Source | Win10
Sponsored By

During the Microsoft Build keynote last week - that you can watch free online here - we snuck in a LOT of detail and easter eggs. We planned the whole thing out like a live stage play (I have a background in theatre) and one of the things that mattered to me was lighting.

If you're going to watch something you for an extended time you'll need a little visual interest. Ya gotta mix it up! So I partnered with LIFX and Isaac Levin to accomplish two things:

  • Can we change room lighting to match Teams/Skype/Slack/Whatever presence status?
  • Can we change room lighting to match the Windows Theme/Background accent color?
    • If I'm not mirroring my pretense status, pull the accent color out and change the light.

Here's what it looked like in the keynote:

Purple light and Purple background
Green light and green background

The PresenceLight app is open source and up on Github by Isaac Levin and you can get it on the Windows Store free or in Chocolatey, WinGet, or download a nightly build.

So what's needed? We need an API to pull presence from and an API to push our chosen color to. So that's the Microsoft Graph that includes presence APIs. On the lighting side, using LIFX as an example, they have a great clean LIFX HTTP API.

RANDOM: If you're looking for my wallpapers from the BUILD keynote, I've put them up here.

Here's what the app looks like. You can auth against Phillips Hue, Yeelight or LIFX. The code for LIFX, as an example, is very clean.

PresenceLight

Check out Isaacs detailed blog post about PresenceLight with code samples and explanations! The LIFX folks also set up a 10% off coupon "BUILD" for use on their online store. I'm sure they'll sell out, but the LIFX Beam that I have is $99 refurbished.


Sponsor: This week's sponsor is...me! This blog and my podcast has been a labor of love for over 18 years. Your sponsorship pays my hosting bills for both AND allows me to buy gadgets to review AND the occasional taco. Join me!

About Scott

Scott Hanselman is a former professor, former Chief Architect in finance, now speaker, consultant, father, diabetic, and Microsoft employee. He is a failed stand-up comic, a cornrower, and a book author.

facebook twitter subscribe
About   Newsletter
Sponsored By
Hosting By
Dedicated Windows Server Hosting by SherWeb

Disclaimer: The opinions expressed herein are my own personal opinions and do not represent my employer's view in any way.