Unable to clone - requires sudo command

I'm working my way through Bit Bucket 101, which up until now has been very good.

I'm at the step where I need to clone the empty repository.  I followed the terminal commands and made a repos folder in the home directory, but when I copy and paste the text from bitbucket in the clone command, I see this:

 

Agreeing to the Xcode/iOS license requires admin privileges, please re-run as root via sudo.

I have absolutely no idea what to do.  Can anyone help?

 

1 answer

1 accepted

This widget could not be displayed.

Run the following:

sudo !!

You should be asked for a password, and then processing will happen, and then all will be well.

Thank you so much for helpig me.  I ran the command sudo !! and this is what happened:

 

You have not agreed to the Xcode license agreements. You must agree to both license agreements below in order to use Xcode.

 

Hit the Enter key to view the license agreements at '/Applications/Xcode.app/Contents/Resources/English.lproj/License.rtf'

 

IMPORTANT: BY USING THIS SOFTWARE, YOU ARE AGREEING TO BE BOUND BY THE FOLLOWING APPLE TERMS:

 

A. MAC SDK AND XCODE AGREEMENT

B. iOS SDK AGREEMENT

 

APPLE INC.

MAC SDK AND XCODE AGREEMENT

 

PLEASE READ THIS MAC SDK AND XCODE AGREEMENT ("LICENSE") CAREFULLY BEFORE USING THE DEVELOPER SOFTWARE (DEFINED BELOW). BY USING THE DEVELOPER SOFTWARE, YOU ARE AGREEING TO BE BOUND BY THE TERMS OF THIS LICENSE.  IF YOU ARE ACCESSING THE DEVELOPER SOFTWARE ELECTRONICALLY, SIGNIFY YOUR AGREEMENT TO BE BOUND BY THE TERMS OF THIS LICENSE BY CLICKING THE "AGREE " BUTTON.  IF YOU DO NOT AGREE TO THE TERMS OF THIS LICENSE, DO NOT USE THE DEVELOPER SOFTWARE AND CLICK “DISAGREE”. 

 

IMPORTANT NOTE: To the extent that this software may be used to reproduce materials, it is licensed to you only for reproduction of non-copyrighted materials, materials in which you own the copyright, or materials you are authorized or legally permitted to reproduce. If you are uncertain about your right to copy any material, you should contact your legal advisor.

 

1. General. 

Software License Agreements Press 'space' for more, or 'q' to quit

Never mind, I followed that...and it all worked out. Strange though.

The more complete explanation is that you need git to complete those exercises, and git is part of XCode. The XCode package for Mac requires admin or "root" privileges to run. The command to run a command as root is "superuser do", which is "sudo" for short. Adding double exclamation points makes it repeat the last command issued. So basically, we just said "do as superuser the last command". This caused XCode to (among other things) present its end user license agreement for your approval. Only after you read through the whole thing was it ready to go.

In short, there was nothing strange about this process, and you should expect this commonly when installing command-line tools.

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Aug 21, 2018 in Bitbucket

Branch Management with Bitbucket

As a project manager, I have discovered that different developers want to bring their previous branching method with them when they join the team. Some developers are used to performing individual wo...

1,260 views 8 11
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you