Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Scripting hidden windows folder$ in OS X

Posted on 2010-11-18
2
Medium Priority
?
487 Views
Last Modified: 2012-05-10
HI there,

trying to run this script but it doesn't work and i am thinking it has something to do with the $ at the end of all users home folders. Could someone maybe help me writing this script correctly

#!/bin/bash
mkdir ~/WindowsHome
mount_smbfs -N //$USER@windows-server.test.com/$USER$ ~/WindowsHome

the leading dollar is the script dollar and the trailing dollar is the hidden folder dollar

any help appreciated lots of points up for grabs here :-)
0
Comment
Question by:timmy-mac
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 12

Accepted Solution

by:
nxnw earned 1500 total points
ID: 34169063
I know nothing about SMB or the particular command you are using, but have you tried using single quotes? I am completely guessing at the syntax here, and am putting this in here just to illustrate what I mean:

mount_smbfs -N //$'USER@windows-server.test.com/$USER$' ~/WindowsHome
0
 

Author Closing Comment

by:timmy-mac
ID: 34169248
You prompted me to the correct solution, the single quotes didn't cut it but I then realised if I put " around the trailing dollar it would print the second dollar and not think it as a syntax

Thanks for the mind nudge
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I was prompted to write this article after the recent World-Wide Ransomware outbreak. For years now, System Administrators around the world have used the excuse of "Waiting a Bit" before applying Security Patch Updates. This type of reasoning to me …
While there are many new features for iOS 11, these are the five that can improve your digital lifestyle.
This Micro Tutorial hows how you can integrate  Mac OSX to a Windows Active Directory Domain. Apple has made it easy to allow users to bind their macs to a windows domain with relative ease. The following video show how to bind OSX Mavericks to …
Michael from AdRem Software explains how to view the most utilized and worst performing nodes in your network, by accessing the Top Charts view in NetCrunch network monitor (https://www.adremsoft.com/). Top Charts is a view in which you can set seve…

604 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question