Scott Hanselman

A rich new JavaScript code editor spreading to several Microsoft web sites

August 1, '13 Comments [33] Posted in Javascript
Sponsored By
Where is this JavaScript-based editable code area coming from?

I noticed yesterday that some C#, JavaScript and CSS files I had sitting in SkyDrive were suddenly editable.

Editable code in SkyDrive

Not just editable, but there's also autocompletion of strings (not quite intellisense, as it's just one file at a time) and token/symbol recognition.

Editable code in SkyDrive

Plus, this editor looked REALLY familiar to me. I started looking.

I looked over at the Windows Azure Portal, where developers can write node.js to make web services directly in the browser. Here we've got dropbox autocomplete, tooltips with syntax errors and even some basic symbolic refactoring!

Azure Mobile Service's rich code editor

Below you can see the editor in Azure Mobile Services throwing a tooltip syntax error. Is this happening on the server?

Untitled2

Then I remember TypeScript's "playground" online that shows how TypeScript turns into JavaScript. This is split-screen with TypeScript on the left and JavaScript on the right.

The TypeScript Playground

Then I went to look at TFS Online's stuff at http://tfs.visualstudio.com/ where I made an account http://hanselman.visualstudio.com to host private Git repos for side projects.

Inline comments in TFS online

Notice that in TFS Online this editor is used for diffs and comparisons, but also includes inline threaded comments! This is all in JavaScript, people.

The editor in a side by side diff

I brought up F12 tools just to check.

The javaScript editor open in SkyDrive

That's pretty unambiguous. Looking at the CSS by just clicking on editor.main.css. The "vs" in the div's class point to a vs-theme.css that I presume is to set the colors and make the text editor look familiar.

editor.main.css

Looking in editor.main.js, it's all minified, but it's cool to see.

editor.main.js

This JavaScript code editor/viewer component is on a TFS site, an Azure site and a SkyDrive site, being used very different divisions across Microsoft. Very cool to see code reuse, but also a good experience replicated. Kudos to the SkyDrive team for recognizing a good thing and putting it into production. It'll be interesting to see where else this editor pops up in the future.

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

Do you have a digital or social media will? Who will maintain your life online when you're dead?

August 1, '13 Comments [22] Posted in Musings
Sponsored By
Will used via CC - Flickr user Ken Mayer http://www.flickr.com/photos/ken_mayer/5599532152/in/photolist-9wP4PN-9wP4Sf-8KxmQx-f7FzSF/

As we continue to pour our few remaining keystrokes into walled gardens we should be asking ourselves - who controls our content? You don't want all your words to be wasted so I hope you own your own domains and have backup copies of all these years of content.

If you die, will everything you've written become a 404? Some people choice to quit the internet, commit infosuicide and make everything return "410 Gone" but most us want our content to live on.

If you die, who will maintain your sites?

If you have kids, you likely have designated a godfather or godmother to raise your kids if you're gone. You should also designate a blogmother and blogfather.

If you  have a Google Account (although, oddly and sadly, not a Google Apps account) you can set up the Google Inactive Account Manager to decide what you want done with your account when it's 'inactive' (you're dead). You can have your data sent to a relative, or have the account deleted. It's a great idea.

You can also sign up for a service like Legacy Locker which promises to manage all your digital stuff and handled the hard questions like "is he or she really dead?" and "are you the digital beneficiary?" At $30 a year or $300 one time it seems a little spendy, but it exists and there's clearly a market for the idea.

Here's what you can do for free.

  • You should already have your content and life backed up in three places, one of which being the cloud.
  • You should have a "Getaway Thumb Drive." This is your "the house is burning, RUN" drive.
    • Consider using TrueCrypt or BitLocker To Go to encrypt one and give a copy to two friends or family members (or lawyer). Make a "readme.txt" or a "soiamdead.txt" explaining what you want done with your sites, passwords, etc."
  • Add your social media sites, blogs, code, repositories and anything else as an asset in your will that is handled by an executor like any other asset.

Even the US Government thinks we need a Social Media Will and I agree. Except for the part where you give your friend an Excel sheet with all your passwords in plaintext. Oh, US Government, you!

They suggest:

  • Review the privacy policies and the terms and conditions of each website where you have a presence.
  • State how you would like your profiles to be handled. You may want to completely cancel your profile or keep it up for friends and family to visit. Some sites allow users to create a memorial profile where other users can still see your profile but can’t post anything new.
  • Give the social media executor a document that lists all the websites where you have a profile, along with your usernames and passwords.
  • Stipulate in your will that the online executor should have a copy of your death certificate. The online executor may need this as proof in order for websites to take any actions on your behalf.
  • Check to see if the social media platforms have account management features to let you proactively manage what happens to your accounts after you die.

You should have a plan for your blog, your domains, and anything that has a login. I use a Password Manager and my family has access to that as well.

This may seem morbid or overwhelming, but this is a project that should take you only a few hours. Imagine your family, spouse or partner in the wake of your death and how it will feel for them, wondering how to manage all this digital flotsam you've left. They'll have no idea where to start. It could take them months, or never, to figure it all out. Just take a few hours and write it down.

* Photo via Ken Mayer on Flickr, used under CC

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

Download Visual Studio 2013 while your feedback still matters

July 30, '13 Comments [141] Posted in ASP.NET
Sponsored By

That's a lovely scrollbar!

Lots of stuff is happening at MSFT right now. Windows 8.1 is around the corner (did you download the 8.1 Preview?) and development is still happening on Visual Studio 2013.

UPDATE: Don't like the Light Theme? The old VS2010 Blue Theme is back, use it instead. Use whatever Theme relaxes you and whatever text colors make you happy.

Change your theme

Use whatever colors make you happy. Here's 2013 with the 2010 theme.

vs2010

Anyway, the ASP.NET and Web Tools team is hard at work on VS 2013 with Web Tools. Remember that the tooling for ASP.NET was pulled out of VS in 2012 and remains an "out of band release." This gives us more flexibility than we had before and will let us get more time to put features in and fix bugs than some groups.

Truth is, the next 4-6 weeks is when we need to be fixing bugs and finding any edge cases or weird stuff. For example, we know that Glimpse doesn't work well with Web Forms and FriendlyUrls. We are actively working on that now.

Download Visual Studio 2013 (and ASP.NET with Web Tools) while your feedback still matters.

What we need from you is bugs and feedback. You can put suff on:

Should you install VS2013?

I have it installed on all my four machines and nothing has broken yet.

Since Visual Studio 2013 installs side-by-side with VS2012 and VS2010, if you already have .NET 4.5 and VS2012 it's not that risky to install VS2013. This has a Go-Live license and includes .NET 4.5.1.

RISK: If you have only VS2010 and .NET 4.0, .NET Framework will upgrade your .NET 4.0 to 4.5.1. If you are shipping to a server with .NET 4 you'll likely be OK, but you ARE taking a risk, so don't use a work machine you deeply care about to test on if you also have to ship .NET 4.0 only code.

BENEFIT: That said, anything that breaks under 4.5.1 we DO want to know about. Meaning, if ASP.NET 4.5.1 breaks your ASP.NET 4 app we need to know and we will only find out if you test. But, don't use the only machine you have to work on every day if it's all you have to ship with.

We would REALLY appreciate folks testing ASP.NET 4.0 apps to run them up ASP.NET 4.5.1 and find bugs. It's that scenario that is the most interesting.

What do you need to get?

All this works in the Free Web Express version so you don't need to have a paid copy of Visual Studio to install VS2013.

Useful VS 2013 features

There's lots of new stuff (check the ASP.NET Release notes) but here's just a few highlights:

Edit and Continue for 64 bit applications - In VS2010 and VS2012, the edit and continue option is disabled by default when creating a new web application project. In VS2013 preview, we turned it on by default. You can find this option on the Web tab in the web project’s properties window.

One ASP.NET with Updated Templates - You'll see this in my talk at BUILD on What's New in ASP.NET and Visual Studio 2013. The dialog isn't done, but we are moving forward with lots of new improvements. Also, ASP.NET includes Twitter Bootstrap out of the box as the default template.

Extensible Scaffolding Framework with new Web Forms Scaffolds and improved MVC scaffolders. You can now enable an ASP.NET app for MVC or Web API and get all the required packages via NuGet. This moves us towards One ASP.NET. There is no "MVC Project Type" or "Web Forms Project Type." There is just one and you can mix and match as you like.

image

Entity Framework has Async Query and Save support, better POCO support, improved perf, connection resiliency, and Code First mapping to Stored Procedures (and more).

VS tooling enhancements - Editor enhancements, Browser Link. There's an all-new HTML editor that understands HTML5 at the core, lots of stuff there but you'll be most impressed with Browser Link (name will likely change)...it's a bi-directional link between ALL running browsers and Visual Studio, powered by SIgnalR.

3324.clip_image001_thumb_10A440B5

So you can do this:

Updating two browsers and an iPhone from VS2013

New Authentication & Identity Model - Auth and ASP.NET Identity is being fixed and rewritten with extensibility in mind. That includes the existing support for Google, Facebook, Microsoft ID, Twitter, Open Auth in general as well as Windows Auth and Windows Azure Activity Directory. (That last one means you can run an intranet app in Azure and authenticate it against your company's existing Active Directory! That means cloud-hosted intranet apps.)

aspnetauth

New Web API and SignalR functionality - Web API now supports Portable Formatters that can be shared on client and server and you can create clients that work on Windows Phone and Windows Store apps. Web API is also updated to support easier Unit Testing of Controllers. Web API also supports AttributeRouting via an OSS contribution from Tim McCall, and CORS via an OSS contribution from Brock Allen. ASP.NET Web API also supports OWIN and OWIN hosts (it can be hosted outside IIS or in your own Service). SignalR now has iOS and Android support via MonoTouch and MonoDroid in Xamarin tools! SignalR also includes a Portable .NET Client.

We are also (quietly) making other changes moving towards bigger ones, including removing the "Windows-only" Restriction for the ASP.NET Project codenamed "Katana" that will be a big part of the next version of ASP.NET and is a part of the plumbing of this release of ASP.NET as well.

A few of my favorite small Non-ASP.NET specific features are viewing method return values in the debugger (duh!)

Return Values

and "Peek Definition" which lets you look at a method definition without opening the file.

Looking at a method definition without opening the file

Also, the return of "RockScroll" in the scrollbar:

That's a lovely scrollbar!

Consider also getting the newly open source "Web Essentials" - This is our "unofficial Labs" extension where we try crazy stuff. We hope you dig it and even better we hope you help us make it all better.

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

Initial Impressions - Intel Haswell 4th Generation Developer Prototype Ultrabook

July 29, '13 Comments [30] Posted in Reviews
Sponsored By
Haswell Intel Prototype

I've reviewed Intel Ultrabooks before that were sent by the software development team at Intel. I review them from a software developer's point of view, so I'm pretty hard on laptops. I want them to be fast, light and fast. They should put up with a development environment being open most of the day, lots of compiling and some virtual machines for good measure.

Last year I looked at the 3rd gen "Ivy Bridge" ultrabooks:

After the Ultrabook experience, I replaced a Lenovo W520 with a Lenovo X1 Carbon Touch as my primary machine. My primary beef with the X1 Carbon is its screen resolution, a barely passable 1400x900, but everything else (plus it's just over 3 pound weight) keeps me using it. However, I get about 5-6 hours typing on the X1 but about 4 hours of "hard work" which just isn't enough considering I'd like to sit AWAY from an electrical outlet for once. If the X1 Carbon Touch had a better 1080p (or better) screen and Haswell, it could be the perfect PC. But do I really need Haswell?

All Ultrabooks are Thin Now

From The Verge, Intel has made some bold statements regarding the Haswell generation:

Intel's been branding the new processor tech as its "largest generational leap ever" with "the biggest performance improvement ever in battery life," as Intel's executive VP of sales and marketing Tom Kilroy boldly stated at Computex's opening keynote speech. The superlatives don't stop there: Navin Shenoy, vice president of the company's PC Client Group, told VentureBeat that "it’s the complete reinvention of the computer as we know it."

imageIntel folks are also saying things like "we can look forward to a 50 percent increase in battery life in the coming wave of devices, with no loss of performance."

So you'll forgive me if I have high expectations. I want this laptop generation to do nothing less than blow my mind.

The software development department at Intel has sent me an Intel Prototype Haswell Ultrabook to review, from a developer's perspective. it's a "no-name" brand (it says Intel on the outside) and it will never be sold. It's a reference hardware example, as it were. I'm not looking to review it as the Ultimate Haswell Laptop, rather as an example Ultrabook with the characteristics I would hope to see in other vendor's Haswell systems.

I will do an in depth review after a month or so of using this, but here's my initial impressions after using this Haswell Laptop exclusively for two full days of actual work.

Size/Weight

Three pounds, baby. That's the standard for nice laptops now. If it's five pounds, it's too heavy. This is a lovely size and a lovely weight. The best part about this Ultrabook is that it's 3.5 lbs and it has a 1080p screen. YES! That's almost enough for me to start using it full time over the Lenovo Carbon X1 Touch. Air-sized is the new size. If it's not this size then I'm not interested in it.

Look/Feel

While this is a prototype that will never be produced, it is definitely nicer than the Ivy Bridge I looked at last year. That one had a lousy keyboard and a nightmare trackpad that has since broken. (My wife can no longer "left click" with that Intel Prototype. This Haswell 4th gen has stepped up the casing part of the hardware, at least, considerably. Remembering that the insides are presumably what this device is aiming to showcase, regardless, the touch pad on this device is WAY better than my X1 (whose touchpad I despise with the heat of a thousand suns) and the keyboard, while it doesn't have Lenovo's legendary quality throw, is still comfortable and fast.

This machine is a matte, almost gunmetal black, with light but firm plastic housing. The major fail is the weak/flimsy power connector, but that's a small complaint. I would also have preferred dedicated page up/down buttons. Otherwise, it's a pleasant and appealing housing.

UPDATE: Sorry, of course, it has a touchscreen, as all Ultrabook's do, by spec definition. It also has a 1080p screen.

Specs/Performance

Setting this machine up from initial boot to a usable machine including Office 2013, Visual Studio 2013 and Windows 8.1 to just 5 hours, working at night watching TV. Mostly it was "next, next, next, finish" as the hard drive light blinked. Part of this is due to the speed of the machine, and part of it is due to newly re-written setup programs. With Office 2013's Click To Run I had Word running in 10 minutes, and VS2013 Pro Preview running in 30. Windows 8.1 took a few hours, and the rest of my developer tools were installed with Chocalatey (apt-get for Windows).

While I wasn't initially impressed with this Ultrabook having only 4 gigs of RAM and an i5 processor (Id' have preferred 8 gigs and an i7), I really haven't noticed a speed difference (yet) against my 3rd-gen i7 Lenovo X1 Carbon. I will do more profiling later to understand the characteristics of this machine and how it affects compilation and app debugging performance.

Battery Life

I have mixed feelings about this. I think the hype machine has us all in its grips. I keep hearing "12 hour battery life" and "all day battery life." But of course I realize that intellectually this means "lower the brightness and watch a movie that has the GPU do all the work and don't touch the laptop all day battery life." It's not "work really hard and compile and run VMs and Outlook and Visual Studio" battery life.

That said, I worked for 6.5 hours before the battery died. It wasn't 12, and it wasn't 10. It was nearly 7 and the brightness was at about 70%. I'm going to wait a bit and do some more formal benchmark. Yes, it's 50% more battery life than the pathetic 4 hours I get now, but it's not all day. Still, the hype machine. I am withholding judgment because it's clearly BETTER, and it's just been a few days.


Disclosure of Material Connection: Intel sent me this Haswell Ultrabook in the hope that I would review it on my blog. Regardless, I only recommend products or services I would use and think you would find useful. This opinions are mine and mine alone as is this entire post. I am disclosing this in accordance with the Federal Trade Commission’s 16 CFR, Part 255: Guides Concerning the Use of Endorsements and Testimonials in Advertising.

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

Choosing the right Portable Power Phone/Tablet/Gadget Battery Charger

July 26, '13 Comments [17] Posted in Hardware | Reviews
Sponsored By

microusb-vs-miniusb[1]I travel a lot and I've talked about the importance of having power while on the go. I carry a small Four Outlet Mini Power Strip, for example, as well as an all-in-one travel plug adapter. I like tools and gadgets that solve more than one problem and/or have multiple-functions.

Until phone and tablet batteries batteries can last for a day of solid use, I also carry a portable battery charger. In fact, I have been testing a bunch over the last few months in search of the Perfect Portable Battery Charger. Spoiler Alert, it doesn't exist yet, but each of these chargers has one of those characteristics.

What do I want? I want a 8000mAh or greater portable charger that weighs less than a pound, has a USB port. It should support a full 2A output for iPads or large tablets, but at LEAST 1A for phones. Bonus points for built in cables for iPhone and micro USB. It should have Solar for emergency charging. Bonus points if it can charge two phones at once, or at least take a 2A load. The fewer dongles or adapters I need to carry, the better.

NOTE: For reference as you read, here's mini-USB vs micro-USB using a photo from PowerLet and Rob Jackson.

What kind of charger do I need?

As you look at these devices and their Pros and Cons, ask yourself these questions:

  • How many times will I need to charge a single phone in a day?
    • Look at your phone's battery and see if one of these batteries will charge it once, twice, or ten times.
  • How large a battery do I want to lug around?
    • Some of these are the weight of your phone, one over a pound and a half. You WILL notice that.
  • Do I live somewhere with a lot of sun and not a lot of outlets?
    • Consider a solar charger, especially if camping (or urban camping)

WakaWaka POWER Smartphone Charger

That black part isn't a phone, that's the battery and on the side is a Solar Cell. The WakaWaka will charge in sunlight in about 8 hours, or in about 4 hours when charge it using micro-USB input.

71-7UCaCJBL._SL1500_WakaWaka

Pros

  • Charges with Solar if needed
  • Extremely light, less than half a pound (200 grams!)
  • Flashlight with several brightness levels, good for camping
  • Small company, supports micro-finance and charitable giving

Cons

  • Only a 2200 mAh Lithium battery.
    • NOTE: Given that an iPhone 4/4s battery has 1420/1430 mAh battery this will give you about a single charge and a bit more. This device would be great with a 6000 mAh battery.

 

myCharge RFAM-0007 Portable Power Bank 6000

This simple and light charger charges with whatever micro-USB AC adapter you already have. It's claim to fame is the three built in cables for charging.

61N9tMfZVbL._SL1436_71cnXqNibzL._SL1500_[1]

Pros

  • Built in old-style iPhone cable. Built in mini- and micro-USB cable.
  • 6000 mAh, very light.

Cons

  • Built in cables are wonky. My iPhone one has failed and no longer charges. I can still charge via the one USB port.
  • In my experience it's power drops off FAST. Feels more like a 2500 mAh device.

Yell BPS66 6600mAh Dual USB Energy Bar

This weirdly shaped battery is a full 6600mAh and weighs only 180 grams (well under a half-pound.) It has a mini-USB in for charging and two USB ports for output. It comes with 8 little adapters, but I haven't used any of them. I just use what came with my phone. It will also charge a large iPad which is a great plus. Charges in about 9 hours.

81ExbDgkRNL._SL1500_201895144254

 

 

Pros

  • Very small and extremely powerful
  • Inexpensive given how much power it packs.

Cons

  • Still needs a mini-USB charger, preferably one that puts out 1A or more.

i.Sound Portable Power Max with 16,000 mAh

Ok, TO BE CLEAR, this thing is a BEAST. It weights 1.4 pounds, almost half what my Ultrabook laptop weighs, but - it puts out an obscene 2.4A if need be and can charge as many as 5 small phones at a time. It adds over 24 hours more usage to an iPad with a 16000mAh battery. This is a great overnight charger.

71n2sddoy-L._SL1500_814rHMTWcKL._SL1500_[1]

Pros

  • 16,000 mAh. There's nothing else that packs this much power. Charges an iPhone 10 times.
  • Up to 6 devices (if you use their splitter, otherwise 5)
  • Flashlight

Cons

  • Requires a proprietary AC charger - Don't lose it!
  • Heavy as heck.

PowerTrip 6000mAh with 50mA Solar Panel

This is a nice charger that plugs right into the wall. The solar panel is very small and will top it up a little in a day of full sunlight, although I've never been able to full the battery only on solar. It's the built in AC that sets it apart.

PowerTrip-with-iPhone-5powertrip2

Pros

  • Built in US AC plug. Just plug the whole charger into the wall. Big win.
  • 6000 mAh, 1.5A output.
  • Small solar panel built in.
  • Comes with three little 6 inch cables for mini, micro and Apple, useful.

Cons

  • Expensive and hard to find, about $100
  • Just one USB port

Related Posts

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.