180 lines
16 KiB
HTML
180 lines
16 KiB
HTML
<?xml version="1.0" encoding="UTF-8"?>
|
||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||
<html xmlns="http://www.w3.org/1999/xhtml" lang="tr" xml:lang="tr">
|
||
<head>
|
||
<!--
|
||
*
|
||
* Copyright 2010-2018, Haiku. All rights reserved.
|
||
* Distributed under the terms of the MIT License.
|
||
*
|
||
* Authors:
|
||
* Humdinger <humdingerb@gmail.com>
|
||
* Translators:
|
||
* Emir SARI
|
||
*
|
||
-->
|
||
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
||
<meta http-equiv="Content-Style-Type" content="text/css" />
|
||
<meta name="robots" content="all" />
|
||
<title>Komut satırı uygulamaları</title>
|
||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||
<link rel="stylesheet" type="text/css" href="../../Haiku-doc.css" />
|
||
</head>
|
||
<body>
|
||
|
||
<div id="banner">
|
||
<div><span>User guide</span></div>
|
||
</div>
|
||
|
||
<div class="nav">
|
||
<div class="inner">
|
||
<ul class="lang-menu">
|
||
<li class="now">Türkçe <span class="dropdown-caret">▼</span></li>
|
||
<li><a href="../../id/applications/cli-apps.html">Bahasa Indonesia</a></li>
|
||
<li><a href="../../ca/applications/cli-apps.html">Català</a></li>
|
||
<li><a href="../../de/applications/cli-apps.html">Deutsch</a></li>
|
||
<li><a href="../../en/applications/cli-apps.html">English</a></li>
|
||
<li><a href="../../es/applications/cli-apps.html">Español</a></li>
|
||
<li><a href="../../fr/applications/cli-apps.html">Français</a></li>
|
||
<li><a href="../../fur/applications/cli-apps.html">Furlan</a></li>
|
||
<li><a href="../../it/applications/cli-apps.html">Italiano</a></li>
|
||
<li><a href="../../hu/applications/cli-apps.html">Magyar</a></li>
|
||
<li><a href="../../pl/applications/cli-apps.html">Polski</a></li>
|
||
<li><a href="../../pt_PT/applications/cli-apps.html">Português</a></li>
|
||
<li><a href="../../pt_BR/applications/cli-apps.html">Português (Brazil)</a></li>
|
||
<li><a href="../../ro/applications/cli-apps.html">Română</a></li>
|
||
<li><a href="../../sk/applications/cli-apps.html">Slovenčina</a></li>
|
||
<li><a href="../../fi/applications/cli-apps.html">Suomi</a></li>
|
||
<li><a href="../../sv_SE/applications/cli-apps.html">Svenska</a></li>
|
||
<li><a href="../../zh_CN/applications/cli-apps.html"> 中文 [中文]</a></li>
|
||
<li><a href="../../ru/applications/cli-apps.html">Русский</a></li>
|
||
<li><a href="../../uk/applications/cli-apps.html">Українська</a></li>
|
||
<li><a href="../../jp/applications/cli-apps.html">日本語</a></li>
|
||
</ul>
|
||
|
||
<span>
|
||
« <a href="list-cli-apps.html">List of commands</a>
|
||
:: <a href="../applications.html#cli-apps" class="uplink">Applications</a>
|
||
</span></div>
|
||
</div>
|
||
|
||
<div id="content">
|
||
<div>
|
||
<div class="box-info">The translation of this page isn't yet complete. Until it is, unfinished parts use the English original.</div>
|
||
|
||
<h2><img src="../../images/apps-images/cli-app-icon_64.png" alt="cli-app-icon_64.png" width="64" height="64" />Haiku komut satırı uygulamaları</h2>
|
||
<table summary="layout" border="0" cellspacing="0" cellpadding="2">
|
||
<tr><td>Konum:</td><td style="width:15px;"></td><td><span class="path">/boot/system/bin/</span><br />
|
||
<span class="path">/boot/system/non-packaged/bin/</span><br /><span class="path">~/config/bin/</span><br /><span class="path">~/config/non-packaged/bin/</span></td></tr>
|
||
</table>
|
||
<p><br /></p>
|
||
<p>Haiku ile gelen tüm komut satırı uygulamaları <span class="path">/boot/system/bin/</span> konumunda yüklüdür. Kendinizin veya sonradan yüklediğiniz .hpkg komut satırı uygulamaları da ya orada ya da <span class="path">~/config/bin/</span> konumunda bulunur. Bu konumların dışında <span class="path">/boot/system/non-packaged/bin/</span> veya <span class="path">~/config/non-packaged/bin/</span> konumlarına da uygulamalar yüklenebilir. Tüm bu konumlar PATH değişkenine dahildir ve kendiliğinden bulunurlar.<br />
|
||
Aşağıda Haiku'ya özel komut satırı uygulamalarının ortalama bir listesini görebilirsiniz, bu liste tüm uygulamaları kapsamamakta olup en kullanışlı olanları listeler. <span class="path">bin/</span> klasöründeki uygulamalara bakıp onlarla oynamaktan çekinmeyin. Bir uygulamayı <tt>--help</tt> parametresi ile başlatmak o uygulamanın seçeneklerini ve kullanımı ile ilgili bilgiyi görüntüler.</p>
|
||
|
||
<h3><a href="#"><img src="../../images/up.png" style="border:none;float:right" alt="index" /></a>
|
||
<a id="cli-attributes" name="cli-attributes">Özniteliklerle ilgili: <span class="cli">listattr</span>, <span class="cli">catattr</span>, <span class="cli">addattr</span>, <span class="cli">rmattr</span>, <span class="cli">copyattr</span></a></h3>
|
||
<p>Bu komutlar dosyaların özniteliklerini görüntüleme, okuma, ekleme ve çıkarma ile ilgilidir. Bu üstveri bilgisi yalnızca BFS ile biçimlendirilmiş disk bölümlerinde kullanılabilir. Bu dosyaları başka dosya sistemi ile biçimlendirilmiş bir diske taşımak tüm bu özniteliklerin kaybolmasına neden olur!<br />
|
||
Tüm bu komutlar <a href="../attributes.html#attributes-terminal">Uçbirim öznitelikleri</a> bölümünde açıklanmıştır.</p>
|
||
|
||
<h3><a href="#"><img src="../../images/up.png" style="border:none;float:right" alt="index" /></a>
|
||
<a id="cli-index" name="cli-index">İndeks ile ilgili: <span class="cli">lsindex</span>, <span class="cli">mkindex</span>, <span class="cli">reindex</span>, <span class="cli">rmindex</span></a></h3>
|
||
<p>Bu komutlarla BFS indeksinin özniteliklerini listeleyebilir, yapabilir, yeniden indeksleyebilir veya kaldırabilirsiniz. Her disk bölümünün kendi özel indeksi vardır, bunu lütfen bir disk bölümünden bir başkasına dosya kopyalarken unutmayın.<br />
|
||
Bu komutlar <a href="../index.html">İndeks</a> bölümünde açıklanmıştır.</p>
|
||
|
||
<h3><a href="#"><img src="../../images/up.png" style="border:none;float:right" alt="index" /></a>
|
||
<a id="cli-pkg" name="cli-pkg">Paket yönetimi ile ilgili: <span class="cli">package</span>, <span class="cli">pkgman</span></a></h3>
|
||
<p><span class="cli">package</span> komutu HPKG paketlerini yönetmede kullanılır. Temel kullanımı öğrenmek için <a href="https://www.haiku-os.org/guides/daily-tasks/install-applications">Installing applications</a> makalesine bir göz atın. Genellikle <a href="https://github.com/haikuports/haikuports/wiki">haikuporter</a> uygulaması kullanılarak "tarif" adı verilen programcıklarla paketler oluşturulur.</p>
|
||
<p><span class="cli">pkgman</span> komutu paketleri aramak, yüklemek, güncellemek ve kaldırmak için kullanılır. Paket depoları eklenebilir, çıkartılabilir ve içlerindeki paketlerin listesi güncellenebilir. <tt>full-sync</tt> komutu kullanılarak daha agresif bir güncelleme yöntemi izlenebilir; bu komut gerektiğinde paketleri kaldırır veya eski bir sürümüne indirebilir.<br />
|
||
Bir parametre hakkında daha fazla bilgi için "--help" bayrağını ekleyin, örn. <tt>pkgman search --help</tt>.</p>
|
||
|
||
<h3><a href="#"><img src="../../images/up.png" style="border:none;float:right" alt="index" /></a>
|
||
<a id="cli-scripting" name="cli-scripting">Betik yazımı için kullanışlı komutlar</a></h3>
|
||
<p>Aşağıda özellikle betik yazımında çok kullanılan komutların bir listesini bulabilirsiniz (ayrıca bkz: <a href="../bash-scripting.html">Bash ve betik yazımı</a>).</p>
|
||
<table summary="scripting cli tools" border="0" cellpadding="2" cellspacing="0">
|
||
<tr><td><p><span class="cli">alert</span></p></td><td style="width:10px;"> </td>
|
||
<td valign="top"><p><span class="cli">alert</span> conjures up the typical alert window with a pre-defined icon, explanatory text and up to three buttons. It will return the title of the pressed button and an exit status (starting with 0). For example, this is made of the line:</p>
|
||
<pre class="terminal">alert --idea "FantasticApp(tm) installed successfully! \
|
||
Would you like a link to it?" "On Desktop" "In Deskbar" "No thanks"</pre>
|
||
<p><img src="../images/apps-images/cli-alert.png" alt="cli-alert.png" /></p>
|
||
</td></tr>
|
||
<tr><td><p><span class="cli">filepanel</span></p></td><td style="width:10px;"> </td>
|
||
<td valign="top"><p><span class="cli">filepanel</span> displays a load or save file panel and lets the user choose a file or location. As a return value you'll get the chosen file or folder's path. There are several parameters available, for example to set a starting directory, a window title, a default name when saving or restrictions to the allowed types of files. This is an example of</p>
|
||
<pre class="terminal">filepanel -s -t "Save your logfile" -d ~/config/settings -n Fantastic.log</pre>
|
||
<p><img src="../images/apps-images/cli-filepanel.png" alt="cli-filepanel.png" /></p>
|
||
</td></tr>
|
||
<tr><td><p><span class="cli">hey</span></p></td><td style="width:10px;"> </td>
|
||
<td valign="top"><p><span class="cli">hey</span> is a littler helper tool that sends BMessages to applications and prints out their answer. It can be used for application scripting, i.e. "remote controlling" a program from a script or the command line. Its usage is a bit complex... <a href="https://www.haiku-os.org/blog/humdinger/2017-11-05_scripting_the_gui_with_hey/">Humdinger's blog post</a> serves as a good introduction, and thanks to Scot Hacker's BeOS Bible, there is a much more comprehensive <a href="http://www.birdhouse.org/beos/bible/bos/ch_scripting6.html">hey tutorial</a> by Chris Herborth.</p>
|
||
</td></tr>
|
||
<tr><td><p><span class="cli">notify</span></p></td><td style="width:10px;"> </td>
|
||
<td valign="top"><p><span class="cli">notify</span> shows a notification panel with a message. There are various parameters that are described when you call <span class="cli">notify --help</span>. A notification can also be used to show the progress of some action. When doing that, it's important to set a <i>messageID</i> and always use it when you update the progress (a float between 0.0 and 1.0 that's printed as percent). Otherwise you'll see several notification panels if you update quicker then the set timeout.<br />
|
||
An example:</p>
|
||
<pre class="terminal">notify --type progress --group "--group" --title "--title" --icon /boot/home/bebook.hvif \
|
||
--messageID MyMessageID --progress .75 "Keep waiting"</pre>
|
||
<p><img src="../images/apps-images/cli-notification.png" alt="cli-notification.png" /></p>
|
||
</td></tr>
|
||
<tr><td><p><span class="cli">query</span></p></td><td style="width:10px;"> </td>
|
||
<td valign="top"><p><span class="cli">query</span> is the commandline version of the Find panel. In fact, a quick way to generate the search term is to build a query in the Find panel, switch to <span class="menu">by formula</span>, add double quotes (<tt>"</tt>) in front and back and paste the whole string after your <span class="cli">query</span> command in Terminal or your script.</p>
|
||
</td></tr>
|
||
<tr><td><p><span class="cli">waitfor</span></p></td><td style="width:10px;"> </td>
|
||
<td valign="top"><p><span class="cli">waitfor</span> is a nice way to wait for a particular application or thread to be started or to have ended.</p>
|
||
</td></tr></table>
|
||
|
||
<h3><a href="#"><img src="../../images/up.png" style="border:none;float:right" alt="index" /></a>
|
||
<a id="cli-other" name="cli-other">Other commands</a></h3>
|
||
|
||
<table summary="scripting cli tools" border="0" cellpadding="2" cellspacing="0">
|
||
<tr><td><p><span class="cli">checkfs</span></p></td><td style="width:10px;"> </td>
|
||
<td><p><span class="cli">checkfs</span> is an important tool to check for errors in your file system. Simply add a volume name like <span class="path">/Haiku</span> or device path and it'll run through every file and correct inconsistencies where possible.</p>
|
||
</td></tr>
|
||
<tr><td><p><span class="cli">desklink</span></p></td><td style="width:10px;"> </td>
|
||
<td valign="top"><p><span class="cli">desklink</span> can install an icon for any file, folder, query or application in the Deskbar tray. It also offers the option to provide a context menu when right-clicking an icon to execute special actions. As an example, try this to add the commandline app <span class="app">screenshot</span> with various options (the "<tt>\</tt>" in the first line is just for the line break in Terminal):</p>
|
||
<pre class="terminal"> desklink "cmd=Active window (2s):/bin/screenshot --window --border --delay 2" \
|
||
"cmd=Remove replicant:desklink --remove=screenshot" /bin/screenshot
|
||
</pre>
|
||
<p><img src="../images/apps-images/cli-desklink.png" alt="cli-alert.png" /></p>
|
||
</td></tr>
|
||
<tr><td><p><span class="cli">diskimage</span></p></td><td style="width:10px;"> </td>
|
||
<td valign="top"><p><span class="cli">diskimage</span> lets you register a regular file as disk device. For example, you can register a Haiku anyboot image, mount it in Tracker and copy, edit or remove files there before using it as source in the Installer.</p>
|
||
</td></tr>
|
||
<tr><td><p><span class="cli">launch_roster</span></p></td><td style="width:10px;"> </td>
|
||
<td valign="top"><p>The launch_daemon starts all sorts of services and applications at boot-up. For some it was instructed to re-start them if they were quit. If you don't want that – maybe you'd like to test a modified Tracker, for example – you use <span class="cli">launch_roster</span> to <tt>stop</tt> the re-starting of the application before quitting it. Similarly, you can <tt>start</tt> it again or get <tt>info</tt> about it.c The parameter <tt>log</tt> prints out a log of all launch_daemon related events.<br />
|
||
Without parameter, <span class="cli">launch_roster</span> lists all apps/services that are under its control.<br />
|
||
For example, this will stop the re-launching of the Deskbar:</p>
|
||
<pre class="terminal">launch_roster stop x-vnd.be-tskb</pre></td></tr>
|
||
<tr><td><p><span class="cli">mountvolume</span><br /><span class="cli">mount</span></p></td><td style="width:10px;"> </td>
|
||
<td valign="top"><p><span class="cli">mountvolume</span> is preferred by many to mount local partitions and disks, because its usage is so easy: just call it with the name of the partition and you're done. Try <tt>--help</tt> for more options.</p>
|
||
<p><span class="cli">mount</span> can additionally mount remote disks by using a network filesystem, like NFS4. You specify the used filesystem with the <tt>-t</tt> parameter and the remote location with the <tt>-p</tt> parameter. As filesystem parameter you can use anything you find in <span class="path">/system/add-ons/kernel/file_system</span> (and corresponding file hierarchies under <span class="path">~/config</span> or "<span class="path">non-packaged</span>", of course). You also have to create a folder as mountpoint. Here's an example:</p>
|
||
<pre class="terminal">mkdir -p /DiskStation
|
||
mount -t nfs4 -p "192.168.178.3:volume1" /DiskStation</pre></td></tr>
|
||
<tr><td><p><span class="cli">open</span></p></td><td style="width:10px;"> </td>
|
||
<td valign="top"><p><span class="cli">open</span> is a very handy little tool. With it you open any file with its preferred application, or start a specific application by its signature without the need to know its exact path. It also works with URLs and even with the "virtual" directories <tt>.</tt> for the current directory and <tt>..</tt> for the parent, opening the folder in Tracker.</p>
|
||
</td></tr>
|
||
<tr><td><p><span class="cli">ramdisk</span></p></td><td style="width:10px;"> </td>
|
||
<td valign="top"><p>A ramdisk is like a harddisk running only in the computer's memory. That makes it very fast but also volatile, because its contents vanishes when you shut down the computer, or it crashes or you experience a blackout.<br />
|
||
To create a ramdisk of 1 GiB, format to the name "RAMses" and mount it, you enter this in Terminal or create a script of it:</p>
|
||
<pre class="terminal">ramdisk create -s 1gb
|
||
mkfs -q -t bfs /dev/disk/virtual/ram/0/raw RAMses
|
||
mountvolume RAMses</pre>
|
||
<p>Note: When creating a ramdisk, the <span class="cli">ramdisk</span> command prints out the path to it. If you create several disks, that path <span class="path">/dev/disk/virtual/ram/0/raw</span> will change!</p>
|
||
<p>To preserve the contents, at least if no calamity like a blackout etc. strikes, a ramdisk can be set up to read/write an image on the harddisk. For that, you need to supply a file of the desired size that will be read from every time you start your ramdisk, and written to when you unmount it. To create an image file "RAMimage" of 500MiB and format it, do this:</p>
|
||
<pre class="terminal">dd if=/dev/zero of=RAMimage bs=500M count=1
|
||
mkfs -q -t bfs /dev/disk/virtual/ram/0/raw RAMimage</pre>
|
||
<p>From now on, you start the ramdisk like this:</p>
|
||
<pre class="terminal">ramdisk create RAMimage
|
||
mountvolume RAMimage</pre>
|
||
<p>It's very important to always cleanly unmount you ramdisk, either from Tracker or with <span class="cli">unmount /RAMimage</span>, or the changes won't be written back to the image file!</p>
|
||
</td></tr>
|
||
</table>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="nav">
|
||
<div class="inner"><span>
|
||
« <a href="list-cli-apps.html">Komutlar listesi</a>
|
||
:: <a href="../applications.html#cli-apps" class="uplink">Uygulamalar</a>
|
||
</span></div>
|
||
</div>
|
||
|
||
</body>
|
||
</html>
|