Thursday, May 12, 2016

Error: EACCES: permission denied, access '/usr/local/lib/node_modules'

If you are wondering what I'm up to these days by setting up Node, npm in a Mac. Well I'm preparing my Mac for SharePoint development. Specifically Apps using client side libraries and scripts.

I'm trying to install Yeoman through the terminal application in Mac and ended up getting the below error.

Error: EACCES: permission denied, access '/usr/local/lib/node_modules'

Though I use Mac, I'm a hardcore Windows user and do my development in Windows and mainly Microsoft technologies. So this error is new to me. Read quite a few blogs to find the correct method to resolve the issue and below is my finding.

Its a permissions issue in the home directory. I need to reclaim the ownership of the npm directory.

sudo chown -R ReplaceWithUserName ~/.npm

Also I need the write permission in to node_modules directory:
sudo chown -R ReplaceWithUserName /usr/local/lib/node_modules

This sorted my issue installing Yeoman.

Wednesday, May 11, 2016

Installing Node.js on OS X El Capitan

I'm new to Node.js. Currently all I know about Node is that it is an asynchronous event driven JavaScript runtime which is designed to build scalable network applications as the official Node site says. All I'm trying to do right now is to setup Node in my Mac and thought of sharing my experience with the community.

To install Node.js, you need to go to the http://nodejs.org where you can download a pre-compiled binary package which is easy to install. I'm going for version 6 with latest features.

You can install the package from the downloaded dmg file. The installation wizard will install Node.js and the npm (Node Package Manager) which is the default package manager for Node.js. Well, this 14MB downloaded file will take nearly 47MB of installation space from your machine. Completion of the installation, check whether the /usr/local/bin is added to your path. Type echo $PATH is the terminal.
As mentioned above, check the path.
Next step is to test the installation as shown below.
You can even check the version of node with the command node -v


This is my first step with Node, along way to go.

Saturday, April 23, 2016

SharePoint Development and DevOps Practices with VSTS

This is an interview I came across in Channel 9. Just thought of sharing it with the community as it shows the real world usage of DevOps in SharePoint Development. Thanks to Vincent Biret and Julien Stroheker for the great insight.



Wednesday, September 30, 2015

Value of SharePoint Add-Ins

I was privileged to conduct a session for ISVs in Sri Lanka which was organized by Microsoft. The whole purpose of the session was to promote the value of SharePoint Add-Ins (formerly Apps).

Wednesday, September 23, 2015

Office 365 Planner

I’m a diehard fan of Trello. I’ve been using it since 2012. All my ideas to implementations are planned and managed in Trello. Not only me, my team uses the same for task allocation, collaboration and tracking. Going beyond the web tool, I uses the mobile app as well. But todays post is not about Trello, but probably a Trello killer. Smile with tongue out

Planner Icon

Microsoft has come up with their own planning software (yet to be released in Q4) in Office 365, which is know as Office 365 Planner. According to Microsoft “Office 365 Planner, which offers people a simple and highly visual way to organize teamwork. Planner makes it easy for your team to create new plans, organize and assign tasks, share files, chat about what you’re working on, and get updates on progress. Planner can be used to manage a marketing event, brainstorm new product ideas, track a school project, prepare for a customer visit, or just organize your team more effectively.”

Planner 1

Planner 2

Planner 3

Office 365 Planner will be available in preview to Office 365 First Release customers starting next quarter, so keep an eye on your Office 365 app switcher.

Planner 4

Happy Planning!

Monday, July 20, 2015

Visual Studio 2015 and .NET 4.6 Available for Download

Few minutes back Microsoft announced the release of Visual Studio 2015 and .Net 4.6.

Microsoft has added tremendous amount of new features in to the new version of VS. According to "Soma" Somasegar, Microsoft’s corporate VP of its Developer Division, “When you think about Visual Studio, the core theme is that VS 2015 is a cross-platform tool set". I'm so existed to test the product, specially the cross platform features.

Soma's blog on VS 2015.





You can see the Visual Studio release note from  here.


Tuesday, July 7, 2015

Deleting a Site Collection Forcefully

Before writing about the solution, let me brief the problem. I was working for one my clients, suddenly I got an error message inside the PowerShell window. I was trying to move a Site Collection using the Move-SPSite cmdlet to a new content database. "A transport-level error has occurred when receiving results from the server" was the error. This is not what I'm going to talk about as I'm still trying to rectify the cause for the same.



Just after the above error, the existing site collection stopped working. Once I select the Site Collection in the "View All Site Collections" in central admin, on the right side of the screen, all I saw was a empty values about the site collection. Even it was without a Content Database. My plan was to delete the site collection and restore the backup. But deleting failed due to the unavailability of the database. Even the Remove-Spsite cmdlet couldn't help me as it can only delete a full provisioned Site Collection. But the below approach worked well.

$siteUrl = “http://mydomain/Site“
$site = get-spsite $siteUrl
$siteId = $site.Id
$siteDatabase = $site.ContentDatabase
$siteDatabase.ForceDeleteSite($siteId, $false, $false)

Thanks to Peter.