Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

General Discussion

indent by one space- macbook pro

How do I indent by one space on my machine? I have a MacBook Pro and Scandinavian (Norwegian) keyboard. To make a square box bracket I therefor press alt+8 or 9. But Command + these keys doesn´t do the anything when trying to practice writing codes here at treehouse.

Im stuck... Please help:-)

5 Answers

I thought it was just the tab key? is your question how do i indent or making square brackets?

How to do indent. It would be nice to be able to do it to larger masses of text thats already written in code... If I use the tab key on each line then its easy to get it all mixed up. I thought...

The course says to use command +square bracket to this...

Maybe I´m complicating things here:-)

Ah right im not sure my self how to do it on a large block of text just single lines.

Well if you have a square bracket symbol on your keyboard you should be able to do it in combination with either command or control button.

If you use an editor such as Sublime Text (you should) you can press CMD + ] to indent and CMD + [ to outdent selected text. Many other editors support this shortcut. If it doesn't work, you could always use SHIFT + CMD + / to search the menus for an "Indent" option :)