2012-09-01 3 views
37

मेरे पास एसटी 2 सेटअप है ताकि मैं 'sublime file.txt' कर सकूं और यह एक एसटी 2 विंडो में खुल जाएगा। लेकिन मैं वर्तमान में खुली खिड़की में एक नए टैब में इसे कैसे खोल सकता हूं?मैं लिनक्स में कमांड लाइन से सब्लिम टेक्स्ट 2 फाइलों को एक टैब पर कैसे खोल सकता हूं, न कि एक नई विंडो

+1

खोलने के लिए मेरी स्थापना में चाहते हैं। आपने SublimeText2 को कैसे इंस्टॉल किया? –

+1

मैंने टारबॉल निष्कर्षण को/usr/lib/made symlink पर ले जाया है: sudo ln -s/usr/lib/sublime \ text \ 2/sublime_text/usr/bin/sublime – phirschybar

उत्तर

47

उदात्त कमांड लाइन मदद का प्रयास करें --help उदात्त पाठ 2 बिल्ड 2217

Usage: subl [arguments] [files]   edit the given files 
    or: subl [arguments] [directories] open the given directories 
    or: subl [arguments] -    edit stdin 

Arguments: 
    --project <project>: Load the given project 
    --command <command>: Run the given command 
    -n or --new-window: Open a new window 
    -a or --add:   Add folders to the current window 
    -w or --wait:  Wait for the files to be closed before returning 
    -b or --background: Don't activate the application 
    -s or --stay:  Keep the application activated after closing the file 
    -h or --help:  Show help (this message) and exit 
    -v or --version:  Show version and exit 

--wait is implied if reading from stdin. Use --stay to not switch back 
to the terminal when a file is closed (only relevant if waiting for a file). 

Filenames may be given a :line or :line:column suffix to open at a specific 
location. 

subl के बाद आप एक नई विंडो बाद फ़ाइलें डिफ़ॉल्ट व्यवहार के अनुसार वहाँ जोड़ा जाना चाहिए खोला है।

+0

[इस userecho] के अनुसार (http: //sublimetext.userecho.com/topic/87972-allow-editing-stdin-on-linux/) और उसी निर्माण के साथ मेरा स्वयं का अनुभव, फ़ाइल के रूप में 'stdin' निर्दिष्ट करना केवल ओएस एक्स –

+0

के साथ एक विकल्प है यकीन नहीं है कि क्या मैं समझता हूं कि यह प्रश्न stdin संपादन से संबंधित है? –

+0

माफी माफी, पहले मैं इस बारे में जानकारी ढूंढ रहा था कि मेरे निर्माण में स्टडीन विकल्प क्यों नहीं था। पता लगाने के बाद मैं उपयोगी परिणाम छोड़ने की कोशिश कर, खोज परिणाम टैब के अपने ढेर के माध्यम से वापस चला गया। यहां कुछ भी नहीं छोड़ा जाना चाहिए :) –

22

यह Ubuntu 12.04 पर काम करता है:

subl filename 

या

subl -n filename

2

एक और विकल्प है (यदि आप इसे एक अलग विंडो में खोलना चाहते हैं): फ़ाइल खोलने के लिए।

[sublime index.html script.js styles.css] 

एक फ़ोल्डर [उदात्त folderName]

3
subl fileName 

खोलने के लिए और यह एक नए टैब में फ़ाइल को खोलता है, तो आप कोई नई फ़ाइल उपयोग

subl -n new_file_name 
संबंधित मुद्दे

 संबंधित मुद्दे