[go: up one dir, main page]

File: cmus.txt

package info (click to toggle)
cmus 2.12.0-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 2,404 kB
  • sloc: ansic: 40,498; sh: 1,642; makefile: 255; python: 157
file content (1850 lines) | stat: -rw-r--r-- 55,233 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
1807
1808
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
@title CMUS 1 31/01/2010 cmus

@h1 NAME

cmus - C\* Music Player


@h1 SYNOPSIS

cmus [*options*]


@h1 DESCRIPTION

cmus is a lightweight ncurses music player. It supports various output methods
by using dynamically-loaded output plugins. cmus has configurable keybindings
and can be controlled externally using *cmus-remote*(1).

@h1 OPTIONS

--listen ADDR
	Listen on ADDR (UNIX socket) instead of `$CMUS_SOCKET` or
	`$XDG_RUNTIME_DIR/cmus-socket`. ADDR must be a UNIX socket or
	host[:port].

	*WARNING*: Using host[:port] is insecure even with a password! It may be
	on a LAN if you want multiple users to be able to control cmus. Never
	expose cmus to the internet.

	NOTE: Don't use this option to run multiple instances as the same user.
	Doing so would corrupt the track metadata cache.

--plugins
	List available plugins and exit.

--show-cursor
	Always display the cursor. This is useful for screen readers.

--help
	Display usage information and exit.

--version
	Display version information and exit.


@h1 VIEWS

There are 7 views in cmus. Press keys 1-7 to change active view.

Library view (1)
	Displays all tracks in the *library*. Tracks are sorted and displayed in
	a tree grouped by artist/album. Artist sorting is done alphabetically.
	Albums are sorted by year.

Sorted library view (2)
	Displays the same content as view 1, but as a simple list automatically
	sorted by user criteria.

Playlist view (3)
	Displays editable playlists with optional sorting.

Play Queue view (4)
	Displays upcoming tracks. These tracks are played before anything else
	(i.e. the playlist or library). Once the queue is empty, playback will
	resume from the last position in the library.

Browser (5)
	Displays the directory browser. In this view, music from the filesystem
	can be added to the library, active playlist, or queue.

Filters view (6)
	Lists user-defined filters.

Settings view (7)
	Lists keybindings, unbound commands and options. Remove bindings with
	*D* or *del*, change bindings and variables with *enter*, and toggle
	variables with *space*.

@h1 COMMAND LINE

Everything in cmus is implemented as commands which can be typed at the command line
or bound to a key. To enter command mode type *:*. To execute a command, press
*ENTER*, and to cancel, press *ESC* or *CTRL-C*. Use up/down arrows to browse
the command history. Use *TAB* to complete commands and parameters. You don't
need to type the full command name if it is unambiguous (no other commands starting
with the same characters).

Examples:

	@pre
	# add files, short for ':add ~/music'
	:a ~/music

	# change output plugin
	:set output_plugin=oss

	# start playing
	# you could just press 'x' which is the default
	# binding for this command
	:player-play

	# clear current view (library, playlist or play queue)
	:clear
	@endpre


@h1 SEARCHING

Search mode works like the command mode. To enter search mode, press */* and
type the query then press *ENTER*. Press *n* to move to the next result or *N*
for the previous one. Type *?* to search backwards.

In views 1-4 the query is matched against the artist, album and title tags. Type
*//WORDS* or *??WORDS* to search only artists/albums in view 1 and only titles
in views 2-4. If the file doesn't have tags, words are compared to the filename
excluding the path.

Searching also works in views 5-7.


@h1 PLAYLIST EDITING

@h2 Selecting Tracks

Editing commands affect the currently marked tracks. If there are no marked
tracks, the currently selected track (or selected artist/album in view 1) is
used.

To mark the selected track, press *SPACE*. Marked tracks appear with a gray
background. You can only mark tracks in the list views (2-4).

@h2 Copying Tracks Between Views

You can copy marked or selected tracks in views 1-5.

@li *a*
copy tracks to the library (1-2)

@li *y*
copy tracks to the marked playlist (3)

@li *e*
append tracks to the play queue (4)

@li *E*
prepend tracks to the play queue (4)

@h2 Moving Tracks

In views 2-4, tracks can be moved within the list. Note that moving is disabled
if the view is auto-sorted (see *lib_sort* and *pl_sort* options).

Pressing *p* moves marked tracks to the position immediately after the selected
track. *P* moves them to the position immediately before the selected track. If
there are no marked tracks, the selected track is moved down (*p*) or up (*P*).

Note that changing active filters in view 2 reloads it, losing any changes made
to the track order.

@h2 Removing Tracks

Press *D* or *delete* to remove the marked or selected tracks in the current
view (1-4). The tracks will be removed immediately from the view without asking
for confirmation. In the browser and filters views, the same keys are used to
remove a file or filter after asking for confirmation.


@h1 STATUS LINE

The right hand side of the status line (second row from the bottom, black text
on a grey background) consists of the following fields:

@pre
aaa_mode & play_sorted & play_library | volume | continue follow repeat shuffle
@endpre

NOTE: *aaa_mode* and *play_sorted* will be only displayed if *play_library* is
*true* because these are meaningless when playing the playlists (view 3).

Pressing *m*, *o*, *M*, *C*, *r* and *s* should make it easier to understand
what these fields mean.

See the CONFIGURATION OPTIONS section for more information about these options.


@h1 KEYBINDINGS

Here's list of default keybindings. To change them, see the *unbind* and *bind*
commands in the COMMANDS section.


@h2 Common: Playback
@pre
b                           player-next
c                           player-pause
x                           player-play
z                           player-prev
v                           player-stop

B                           player-next-album
Z                           player-prev-album

]                           vol +0 +1%
[                           vol +1% +0
+                           vol +10%
=                           vol +10%
}                           vol -0 -1%
{                           vol -1% -0
-                           vol -10%

,                           seek -1m
.                           seek +1m

h                           seek -5
l                           seek +5

left                        seek -5
right                       seek +5

mlb_click_bar               player-pause
mlb_click_bar_right         player-pause
mouse_scroll_up_bar         seek +5
mouse_scroll_down_bar       seek -5
mouse_scroll_up_bar_right   vol +1%
mouse_scroll_down_bar_right vol -1%
@endpre

@h2 Common: Setting Toggles
@pre
m                       toggle aaa_mode
C                       toggle continue
M                       toggle play_library
o                       toggle play_sorted
r                       toggle repeat
^R                      toggle repeat_current
t                       toggle show_remaining_time
s                       toggle shuffle
f                       toggle follow
@endpre

@h2 Common: Commands
@pre
q                       quit -i
^C                      echo Type :quit<enter> to exit cmus.
I                       echo {}

!                       push shell<space>
@endpre

@h2 Common: View/Window Navigation
@pre
1                       view tree
2                       view sorted
3                       view playlist
4                       view queue
5                       view browser
6                       view filters
7                       view settings

mouse_scroll_up_title   left-view
mouse_scroll_down_title right-view

tab                     win-next

^L                      refresh
@endpre

@h2 Common: Navigation
@pre
^Y                      win-scroll-up
^E                      win-scroll-down
^B                      win-page-up
^F                      win-page-down
^U                      win-half-page-up
^D                      win-half-page-down

k                       win-up
j                       win-down
g                       win-top
G                       win-bottom

up                      win-up
down                    win-down
home                    win-top
end                     win-bottom
page_up                 win-page-up
page_down               win-page-down

mouse_scroll_up         win-up
mouse_scroll_down       win-down
@endpre

@h2 Common: Selection
@pre
i                       win-sel-cur
enter                   win-activate
mlb_click_selected      win-activate

space                   win-toggle
D                       win-remove
delete                  win-remove
p                       win-mv-after
P                       win-mv-before

E                       win-add-Q
a                       win-add-l
y                       win-add-p
e                       win-add-q

u                       update-cache
U                       win-update-cache
@endpre

@h2 Common: Filters
@pre
/                       search-start
?                       search-b-start
n                       search-next
N                       search-prev

F                       push filter<space>
L                       push live-filter<space>
@endpre

@h2 File Browser
@pre
space                   win-activate
backspace               browser-up
i                       toggle show_hidden
u                       win-update
@endpre


@h1 LIBRARY VIEW SORTING

The library view (the tree-like one; not the sorted library view, which is
configured with lib_sort - see `CONFIGURATION OPTIONS`), is sorted automatically
using tags from the audio files.

Note: Albums which feature various artists (e.g. samplers or compilations) are
treated specially. If an album artist tag or the ID3v2 *TPE2* frame is set, it
will be used instead of the real artist name. Otherwise, cmus determines if the
album is a compilation (if *albumartist* or *artist* are set to *Various
Artists*, *Various*, *VA*, or *V/A*; or if *compilation* or *partofacompilation*
are set to a truthy value; or if the ID3v2 *TCMP* frame is set). If so, the
artist is named *<Various Artists>*.

Note: If the filename is a URL, the artist/album tags are set to *<Stream>*. If
it is a file, cmus sets the artist and/or album tags to *<No Name>* if they are
not already set. These names will be treated the same way as other names for
sorting.

In general, three levels of sorting are used in the library view: the artist
name, then the album, and finally the track itself.

First, cmus sorts alphanumerically by the value of the artist tag. If a special
sorting tag is available, its value will be used instead.

Next, cmus sorts by the album. Tracks are grouped by the album name, and the
groups are sorted by the date of the first track, then alphanumerically by the
name of the album. If the date header is not set, the album will be placed on
top of the list.

Finally, each album is sorted by the track *discnumber*, *tracknumber*, then
filename (not the track name).


@h1 COMMANDS

This section describes cmus' commands, which can be bound to keys and mouse
events, put in configuration files, executed in command mode, or passed to
cmus-remote.

Optional parameters are in [brackets], required parameters in <angle brackets>
and default key bindings are (parenthesized).

add [-l] [-p] [-q] [-Q] <file|dir|url|playlist>
	Adds file/dir/url/playlist to the specified view or the current view.

	@li -l
	add to library

	@li -p
	add to playlist

	@li -q
	add play queue

	@li -Q
	prepend to play queue

	Supported files are based on the loaded input plugins.

	Supported URLs: Shoutcast (`http://`...), CDDA (`cdda://`...).

	Supported playlist types: plain, .m3u, .pls.

bind [-f] <context> <key> <command>
	Adds a key binding.

	@li -f
	overwrite existing binding

	Valid contexts: common (i.e. all views), library (1-2), playlist (3),
	queue (4), browser (5), filters (6)

	There's one context for each view. Common is a special context on which
	bound keys work in every view.

	You can override specific keys in common context for a view. For example
	*i* selects the current track in views 1-3 but in browser it is
	overridden to toggle showing of hidden files.

	When setting custom bindings in `$XDG_CONFIG_HOME/cmus/rc`, it is
	recommended to use the -f option, or else bind may fail due to an
	existing binding in the autosave or system-level config files.

	Hint: You can press *tab* from command mode to expand contexts, keys,
	and commands.

browser-up (*backspace*)
	Navigates the browser view to the parent directory (5). This command
	only makes sense to be bound to the *browser* key context although it's
	possible to use this even if browser view is not active.

cd [directory]
	Changes the current working directory. Also changes the directory
	displayed in the browser view.

clear [-l] [-p] [-q]
	Removes all tracks from a single view.

	@li -l
	clear library

	@li -p
	clear playlist

	@li -q
	clear play queue

	If a view is not specified, the current view is used.

colorscheme <name>
	Changes the color scheme. Color schemes are found in `/usr/share/cmus/`
	or `$XDG_CONFIG_HOME/cmus/` and have the extension *.theme*.

echo <arg>...
	Displays the arguments on the command line.

	*{}* it is replaced with file name of the first selected track.

factivate <user-defined-filter>...
	Selects and activates the given user defined filters (displayed in the
	filters view). Filter names are separated by spaces. This command is
	mostly useful when bound to a key to change active filters quickly. If
	no arguments are provided, all filters are deactivated.

	Prefix a filter name with *!* to negate it.

filter <filter-expression>
	Temporarily filters a library view. The filter is not saved (use *fset*
	and *factivate* for that).

fset <name>=<filter-expression>
	Defines or replaces an existing filter and adds it to the filters view
	(6).

help
	Shows information about help files.

invert
	Inverts the marking of tracks in playlist and queue views. See *mark*
	and *unmark*.

live-filter <simple-filter-expression|short-filter-expression>
	Like filter, but uses simple filters and shows a preview as you type. It
	persists even after leaving command mode.

load [-l] <playlist>
	Loads a playlist to a view.

	@li -l
	load to library views

	If a view is not specified, the current view is used, which must be 1-2.

lqueue [NUM]
	Queues NUM (default 1) random albums from the library. Also see
	*tqueue*.

mark <filter-expression>
	Marks tracks in playlist and queue view using a filter expression.

mute
	Toggles mute for the sound output.

pl-create <name>
	Creates a new playlist.

pl-delete [-a] <name>
	Deletes the playlist with the given name.

	-a
		Deletes all playlists

pl-export <filename>
	Exports the currently selected playlist. The file will be overwritten if
	it exists.

pl-import [filename]
	Imports a playlist into the playlist view. The argument can be omitted in
	the file browser view.

pl-rename <name>
	Renames the selected playlist.

player-next (*b*)
	Skips to the next track.

player-next-album (*B*)
	Skips to the next album. If *shuffle*=`tracks` or a playlist is active,
	skips to the next track.

player-pause (*c*)
	Toggles pause.

player-pause-playback
	Pauses if currently playing.

player-play [filename] (*x*)
	Plays the given track, or, if none is specified, [re]plays the current
	track from the beginning.

player-prev (*z*)
	Skips to the previous track.

player-prev-album (*Z*)
	Skips to the previous album. If *shuffle*=`tracks` or a playlist is active,
	skips to the previous track.

player-stop (*v*)
	Stops playback.

prev-view
	Goes to the previously used view.

left-view [-n]
	Goes to the to view to the left of current one (e.g. view 4 -> view 3)

	@li -n
	no cycle back to end when reaching the first view

right-view [-n]
	Goes to view to the right of current one (e.g. view 3 -> view 4).

	@li -n
	no cycle back to start when reaching the last view


push [text]
	Enters command mode with the command line pre-set to text. Example:

		bind common w push filter artist=

	Text can contain spaces, which will be used as-is (e.g. trailing spaces
	will be preserved). If no text is given, it defaults to a blank command
	line.
	
	This command can only be used from a keybinding.

pwd
	Prints the current working directory.

quit [-i] (*q*, *:wq*)
	Exits cmus.

	@li -i
	ask before exiting

raise-vte
	Raises the virtual terminal emulator window. Only works within a X
	session.

rand
	Randomizes (shuffles) the tracks in the library, playlist or queue view.

refresh (*^L*)
	Redraws the terminal window.

reshuffle
	Reshuffles the shuffle lists for both library and playlist views.

run <command>
	Runs a command for the marked tracks OR the selected one if none marked.

	By default file names are appended to the command. If the command
	contains *{}* it is replaced with list of filenames.

	Note: In view 1 you can run a command for all files in the selected
	album or artist.

save [-e]  [-l] [-L] [-p] [-q]  [file]  (*:w*)
	Saves the contents of a view to a playlist file. In extended mode (-e),
	also saves track metadata.

	@li -l
	save library views

	@li -L
	save filtered library views

	@li -p
	save playlist view

	@li -q
	save queue view

	If no view is specified, the current one is used.

	If no filename given the old filename is used. "-" outputs to stdout
	(works only remotely).

search-b-start
	Enters backwards search mode. Cannot be used directly from command mode.

	See *search-start*.

search-next (*n*)
	If there is an active search, goes to the next match in the current
	view. See *SEARCHING* above.

search-prev (*N*)
	If there is an active search, goes to the previous match in the current
	view. See *SEARCHING* above.

search-start
	Enters search mode. Cannot be used directly from command mode.

	This is similar to live-filter, except it is temporary and only selects
	the current match rather than filtering the entire view.

seek [+-](<num>[mh] | [HH:]MM:SS)
	Seeks to an absolute or relative position, which can be given in
	seconds, minutes (m), hours (h) or HH:MM:SS format where HH: is
	optional.

	Seek 1 minute backward
		:seek -1m

	Seek 5 seconds forward
		:seek +5

	Seek to absolute position 1h
		:seek 1h

	Seek 90 seconds forward
		:seek +1:30

set <option>=<value>
	Sets the value of an option. See *OPTIONS*.

set <option>
	Display option value. Vim compatible *set <option>?* is also
	supported.

shell <command>
	Executes a command via /bin/sh -c.

showbind <context> <key>
	Shows a key binding.

source <filename>
	Reads and executes commands from <filename>.

toggle <option>
	Toggles the value of a toggle-able option (all booleans and the options
	*shuffle*, *aaa_mode*, and *replaygain*).

tqueue [NUM]
	Queues NUM (default 1) random tracks from the library. See also
	*lqueue*.

unbind [-f] <context> <key>
	Removes a key binding. Use tab to cycle through bound keys.

	-f
		Don't throw an error if the binding is not known

unmark
	Unmarks all tracks (see *mark*).

update-cache [-f]
	Updates the track metadata cache ($XDG_CONFIG_HOME/cmus/cache). By
	default, only deletions or files with a changed modification time are
	updated.

	-f
		Update all files. Same as quit, rm -f $XDG_CONFIG_HOME/cmus/cache, start cmus.

version
	Prints the version information.

view <name or 1-7>
	Changes the active view.

	Do not use this in `$XDG_CONFIG_HOME/cmus/rc` to change the starting
	view. Set the *start_view* option instead.

vol [+-]NUM[%] [[+-]NUM[%]]
	Changes the volume.

	If a single argument is provided, both channels are changed. Otherwise,
	the first/second values are for the left/right channels respectively.

	To increase or decrease volume prefix the value with *-* or *+*,
	otherwise value is treated as absolute volume.

	Both absolute and relative values can be given as percentage units
	(suffixed with *%*) or as internal values (hardware may have volume in
	range 0-31 for example).

w
	See *quit*. Intended for use while in command mode.

win-activate (*enter*)
	In views, 1-3 plays the selected track. In view 5 starts, the selected
	file or changes to the selected directory. In view 6, activates the
	selected filters. In settings view (7), changes a binding or variable.

win-add-l [-n] (*a*)
	Adds the currently marked or selected track(s) (views 3-4), or the
	currently selected file/directory (view 5), to the library.

	Analogous to *:add -l*

	-n
		Don't move the selection to the next item.

win-add-p [-n] (*y*)
	Adds the currently marked or selected track(s) (views 1-2, 4), or the
	currently selected file or directory (view 5), to the marked playlist.

	Analogous to *:add -p*

	-n
		Don't move the selection to the next item.

win-add-Q [-n] (*E*)
	Prepends the currently marked or selected track(s) (views 1-3), or the
	currently selected file or directory (view 5), to the play queue.

	Analogous to *:add -Q*

	-n
		Don't move the selection to the next item.

win-add-q [-n] (*e*)
	Adds the currently marked or selected track(s) (views 1-3), or the
	currently selected file or directory (view 5), to the play queue.

	Analogous to *:add -q*

	-n
		Don't move the selection to the next item.

win-bottom (*G*, *end*)
	Goes to bottom of the current window.

win-down [NUM] (*j*, *down*)
	Goes down NUM (default 1) rows in the current window.

win-half-page-down (*^D*)
	Goes down half a page in the current window.

win-half-page-up (*^U*)
	Goes up half a page in the current window.

win-mv-after (*p*)
	Moves the marked tracks below the selected track. If no tracks are
	selected, selects the previous track. If no tracks are marked, moves the
	selected track up by one. This command works in the playlist and queue
	views.

win-mv-before (*P*)
	Moves the marked tracks above the selected track. If no tracks are
	selected, selects the previous track. If no tracks are marked, moves the
	selected track down by one. This command works in the playlist and queue
	views.

win-next (*tab*)
	Activates the next window (i.e. tree/list). Only relevant in view 1.

win-page-bottom
	Goes to the bottom of the visible part of the current window.

win-page-down (*^F*, *page_down*)
	Goes to down one page in the current window.

win-page-middle
	Goes to the middle of the visible part of the current window.

win-page-top
	Goes to the top of the visible part of the current window.

win-page-up (*^B*, *page_up*)
	Goes up one page in the current window.

win-remove (*D*, *delete*)
	Removes the selected entry. For tracks, no confirmation is required. For
	playlists (view 3), files (view 5), filters (view 6) and bindings (view
	7) user must confirm the action.

win-scroll-down (*^E*)
	Scrolls the current window one row downwards.

win-scroll-up (*^Y*)
	Scrolls the current window one row upwards.

win-sel-cur (*i*)
	Selects the current track (position in library or playlist, not
	necessarily same as the currently playing track). Works only in views
	1-3, does nothing in other views.

win-toggle (*space*)
	Expands albums in library view (1), marks tracks in views 2-4, sets the
	marked playlist in view 3, toggles selection of a filter in view 6,
	or toggles a variable's value in view 7.

win-top (*g*, *home*)
	Goes to top of the current window.

win-up [NUM] (*k*, *up*)
	Goes up NUM (default 1) rows in the current window.

win-update (*u*)
	Checks the modification time of the files in the library, and updates
	metadata for changed files. Removes non-existent files from the library.

	Reloads contents of directory in the browser view.

	Only works in views 1-2 and 5, does nothing in other views.

win-update-cache [-f]
	Same as *update-cache*, but only for marked / selected tracks.
	Only works in views 1-2, does nothing in other views.

wq
	See *quit*. Intended for use from command mode.


@h1 CONFIGURATION OPTIONS

This section describes configuration options used by cmus.

These options can be changed using the *set* and *toggle* commands. Default
values are (parenthesized), and the possible values are in [brackets].

auto_expand_albums_follow, auto_expand_albums_search, auto_expand_albums_selcur (true)
	Always expand an artist and select the album when following the
	currently played track or performing actions such as "search" or "go to
	current track". This option is tightly coupled to the show_all_tracks
	option. Any "auto_expand_albums_\* = false" implies "show_all_tracks =
	true".

auto_hide_playlists_panel (false)
	Hide the left panel in playlist view. The panel will show as needed when
	activated with win-next (*tab*).

auto_reshuffle (true)
	Reshuffle a playlist when the end of a shuffled list is reached.

aaa_mode (all) [all, artist, album]
	Defines what tracks should be played in the library view. Not used in
	the other views.
	
	For example, if set to *artist*, the player behaves like there were only
	the files of the currently playing artist in the library.

altformat_current [`Format String`]
	Alternative format string for the line displaying currently playing
	track.

	Note: If empty, *format_current* is used instead.

altformat_playlist [`Format String`]
	Alternative format string for the list views (2-4).

	Note: if empty, *format_playlist* is used instead.

altformat_title [`Format String`]
	Alternative format string the for terminal title.

	Note: not all terminals support changing window title.

	Note: if empty, *format_title* is used instead.

altformat_trackwin [`Format String`]
	Alternative format string for the tree view's (1) track window.

	Note: if empty, *format_trackwin* is used instead.

block_key_paste (true)
	Prevent accidental input by only accepting pasted text in the command line.
	Only works on terminals which support bracketed paste.

buffer_seconds (10) [1-300]
	Size of the player buffer in seconds.

color_cmdline_bg (default) [`Color`]
	Command line background color.

color_cmdline_fg (default) [`Color`]
	Command line foreground color.

color_cmdline_attr (default) [`Attributes`]
	Command line attributes.

color_error (lightred) [`Color`]
	Color of error messages displayed on the command line.

color_info (lightyellow) [`Color`]
	Color of informational messages displayed on the command line.

color_separator (blue) [`Color`]
	Color of the separator line between windows in view (1).

color_statusline_bg (gray) [`Color`]
	Status line background color.

color_statusline_fg (black) [`Color`]
	Status line foreground color.

color_statusline_attr (default) [`Attributes`]
	Status line attributes.

color_statusline_progress_bg (blue) [`Color`]
	Status line background color of progress bar, when enabled.

color_statusline_progress_fg (white) [`Color`]
	Status line foreground color of progress bar, when enabled.

color_statusline_progress_attr (default) [`Attributes`]
	Status line attributes of progress bar, when enabled.

color_titleline_bg (blue) [`Color`]
	Background color of the line displaying currently playing track.

color_titleline_fg (white) [`Color`]
	Foreground color of the line displaying currently playing track.

color_titleline_attr (default) [`Attributes`]
	Attributes of the line displaying currently playing track.

color_win_bg (default) [`Color`]
	Window background color.

color_win_cur (lightyellow) [`Color`]
	Color of currently playing track.

color_win_cur_attr (default) [`Attributes`]
	Currently playing track attributes.

color_win_cur_sel_bg (blue) [`Color`]
	Background color of the selected row which is also the currently
	playing track in active window.

color_win_cur_sel_fg (lightyellow) [`Color`]
	Foreground color of the selected row which is also the currently
	playing track in active window.

color_win_cur_sel_attr (default) [`Attributes`]
	Attributes of the selected row which is also the currently
	playing track in active window.

color_win_dir (lightblue) [`Color`]
	Color of directories in browser.

color_win_fg (default) [`Color`]
	Window foreground color.

color_win_attr (default) [`Attributes`]
	Window attributes.

color_win_inactive_cur_sel_bg (gray) [`Color`]
	Background color of the selected row which is also the currently
	playing track in inactive window.

color_win_inactive_cur_sel_fg (lightyellow) [`Color`]
	Foreground color of the selected row which is also the currently
	playing track in inactive window.

color_win_inactive_cur_sel_attr (default) [`Attributes`]
	Attributes of the selected row which is also the currently
	playing track in inactive window.

color_win_inactive_sel_bg (gray) [`Color`]
	Background color of selected row in inactive window.

color_win_inactive_sel_fg (black) [`Color`]
	Foreground color of selected row in inactive window.

color_win_inactive_sel_attr (default) [`Attributes`]
	Attributes of selected row in inactive window.

color_win_sel_bg (blue) [`Color`]
	Background color of selected row in active window.

color_win_sel_fg (white) [`Color`]
	Foreground color of selected row in active window.

color_win_sel_attr (default) [`Attributes`]
	Attributes of selected row in active window.

color_win_title_bg (blue) [`Color`]
	Background color of window titles (topmost line of the screen).

color_win_title_fg (white) [`Color`]
	Foreground color of window titles (topmost line of the screen).

color_win_title_attr (default) [`Attributes`]
	Attributes of window titles (topmost line of the screen).

color_trackwin_album_bg (default) [`Color`]
	Background color of the album row shown in the track window.

color_trackwin_album_fg (default) [`Color`]
	Foreground color of the album row shown in the track window.

color_trackwin_album_attr (bold) [`Attributes`]
	Attributes of the album row shown in the track window.

confirm_run (true)
	Ask for confirmation before executing *:run*

continue (true)
	Continue playing after current track finishes.

continue_album (true)
	Continue playing next album after current album finishes.

device (/dev/cdrom)
	CDDA device file.

display_artist_sort_name (false)
	If enabled, always displays artist names used for sorting instead of
	regular ones in tree view (e.g. "Artist, The" instead of "The Artist"),
	so that artists column looks alphabetically sorted.

follow (false)
	If enabled, always select the currently playing track on track change.

format_clipped_text [`Plain String`]
	String used to lead out any text that is cut off by field limits.

	Note: `Format String` rules are not applied. A plain string such as "..."
	is expected.

format_current [`Format String`]
	Format string for the line displaying currently playing track.

format_heading_album [`Format String`]
	Format string for the track window heading line when an album is selected
	in the tree.

format_heading_artist [`Format String`]
	Format string for the track window heading line when an artist is selected
	in the tree.

format_heading_playlist [`Format String`]
	Format string for the heading line in the playlist view (3).

format_playlist [`Format String`]
	Format string for the list views (2-4).

format_playlist_va [`Format String`]
	Format string for the list views (2-4), if a track is assumed to be a
	part of compilation (see `LIBRARY VIEW SORTING` for details).

	Note: If empty, *format_playlist* is used instead.

format_statusline [`Format String`]
	Format string for status line.

format_title [`Format String`]
	Format string for terminal title.

	Note: Not all terminals support changing window title.

format_trackwin [`Format String`]
	Format string for the tree view's (1) track window.

format_trackwin_album [`Format String`]
	Format string for albums in tree view's (1) track window.

format_trackwin_va [`Format String`]
	Format string for the tree view's (1) track window, if a track is
	assumed to be a part of compilation (see `LIBRARY VIEW SORTING` for
	details).

	Note: If empty, *format_trackwin* is used instead.

format_treewin [`Format String`]
	Format string for the tree view's (1) tree window.

format_treewin_artist [`Format String`]
	Format string for artists in tree view's (1) tree window.

smart_artist_sort (true)
	If enabled, makes the tree view sorting ignore "The" in front of artist
	names, preventing artists starting with "The" from clumping together.
	Real `artistsort` tags override this option, if present.

sort_albums_by_name (false)
	In tree view (1), albums will be sorted by name rather than date.

id3_default_charset (ISO-8859-1)
	Default character set to use for ID3v1 and broken ID3v2 tags.

	Note: This is used only if the tag is not valid UTF-8.

icecast_default_charset (ISO-8859-1)
	Default character set to use for non-UTF-8 icecast stream metadata.

	Note: This is used only if the metadata is not valid UTF-8.

ignore_duplicates (false)
	Ignore duplicates when adding tracks to the library. A track is a duplicate
	if it has a matching artist, album, disc number, track number, and track
	name.

lib_add_filter [`Filter`]
	Apply filter when adding files to the library. See *FILTERS*.

lib_sort (artist album discnumber tracknumber title filename) [`Sort Keys`]
	Sort keys for the sorted library view (2).

mouse (false)
	Enable mouse support.

	Note: Mouse wheel scrolling can lag if cmus is compiled with
	old version of ncurses.

mpris (true)
	Enable MPRIS support. See *D-Bus Interface (MPRIS)*

	Note: This flag has no effect if cmus was compiled without MPRIS support.

output_plugin [roar, pulse, alsa, arts, oss, sndio, sun, coreaudio, aaudio]
	Name of output plugin.

passwd [`password`]
	Set the password for TCP/IP connections. Required if listening on
	host[:port]. No effect if listening on a UNIX socket. Used in
	conjunction with --listen.

pause_on_output_change (false)
	Pauses playback when the audio output changes.

	Supported output plugins: pulse, aaudio.

pl_env_vars
	Comma separated list of environment variables to substitute when saving
	library/playlist files. The paths must be absolute to take effect. See
	`Library Environment Variables`.

	Note: This option will not take full effect until cmus has been restarted.

pl_sort () [`Sort Keys`]
	Sort keys for the playlist view (3). Empty value disables sorting and
	enables manually moving tracks.

play_library (true)
	Play tracks from the library instead of playlist.

play_sorted (false)
	Play tracks from the library in the sorted view (2) order instead of
	tree view (1) order. Used only when play_library is true.

progress_bar (line) [disabled, line, shuttle, color, color_shuttle]
	Draw a bar in the status line showing current progression through a track.

repeat (false)
	Repeat after all tracks played.

repeat_current (false)
	Repeat current track forever.

replaygain (disabled) [track, album, track-preferred, album-preferred, smart]
	Enable Replay Gain. The smart setting behaves like track-preferred when
	shuffle is on, or the queue is active, or when playing from a playlist.
	Otherwise, it behaves like album-preferred.

replaygain_limit (true)
	Use replay gain limiting when clipping.

replaygain_preamp (0.0)
	Replay gain preamplification in decibels.

resume (false)
	Resume playback on startup.

rewind_offset (5) [-1-9999]
	If the position of the current track is smaller than rewind_offset,
	player_prev jumps to the previous track. Otherwise, player_prev jumps to
	the beginning of the current track. If rewind_offset=-1, player_prev
	always jumps to the previous track.

scroll_offset (2) [0-9999]
	Minimal number of screen lines to keep above and below the cursor.

search_resets_position (true)
	Starts searches at the beginning of the current view rather than the
	current item.

show_all_tracks (true)
	Display all tracks of the artist when the artist is selected in the tree
	view. This option is tightly coupled to the auto_expand_albums_\*
	options. "show_all_tracks = false" implies "auto_expand_albums_\* =
	true".

show_hidden (false)
	Display hidden files in browser.

show_current_bitrate (false)
	Display current bitrate in the status lines.

show_playback_position (true)
	Display elapsed (or remaining) time in the status line. Can be disabled
	to e.g. not trigger tmux's activity monitor.

show_remaining_time (false)
	Display remaining time instead of elapsed time.

shuffle (off) [off, tracks, albums]
	@li *off*
	Play all tracks in order. See also *lib_sort* and *pl_sort*.
	@li *tracks*
	Play all tracks in the library or playlist in a shuffled order.
	@li *albums*
	Play each library album to completion before shuffling to the first track
	of another library album. In playlists this option falls back to *tracks*
	behaviour.

	Filters and *aaa_mode* can be used to limit the items available for play.
	Note that *shuffle*=`albums` will have no effect with *aaa_mode*=`album`.

skip_track_info (false)
	Don't load metadata when adding tracks. Useful when using network file
	system and having huge amount of files. Tags can be loaded using
	'update-cache' or 'win-update-cache' commands.

softvol (false)
	Use software volume control.

	Note: You should probably set this to false when using *ao* as
	*output_plugin* to output to wav files.

softvol_state (100 100)
	Used to save left and right channel values for software volume control.
	Two integers in range 0..100 separated by a space. This option is not
	usually changed directly since *vol* command does same thing if
	*softvol* is true.

start_view (tree) [tree, sorted, playlist, queue, browser, filters, settings]
	Specify the view that gets shown when cmus starts.

status_display_program () [command]
	This command, if set, is run for every status change. It can be used to
	display currently playing track on desktop background or panel for
	example. See `/usr/share/doc/cmus/examples/cmus-status-display`.

stop_after_queue (false)
	Stop playback when end of play queue is reached.

time_show_leading_zero (true)
	Pad durations of less than 10 minutes with a leading 0.

tree_width_percent (33) [1-100]
	Percentage of the window width to use for left pane.

tree_width_max (0) [0-9999]
	Restrict the size calculated from tree_width_percent. 0 disables this
	option.

	This affects the tree in the library view and the playlist list in the
	playlist view.

	Note that this value will be further constrained by the window width
	and/or the minimum tree size.

	For example, to set a fixed size of 60 columns:

		@pre
		set tree_width_percent=100
		set tree_width_max=60
		@endpre

	Or, to be 33% wide, but at most 60 columns

		@pre
		set tree_width_percent=33
		set tree_width_max=60
		@endpre

	Or, to always be 33% wide where possible (the default behavior):

		@pre
		set tree_width_percent=33
		set tree_width_max=0
		@endpre

wrap_search (true)
	Controls whether the search wraps around the end.

@h2 Colors

Color is an integer in range -1..255.

The following color names are recognized:

Terminal's default color, -1
	default

Fg & bg, 0..7
	black, red, green, yellow, blue, magenta, cyan, gray

Fg, 8..15
	darkgray, lightred, lightgreen, lightyellow, lightblue, lightmagenta,
	lightcyan, white

@h2 Attributes

Attributes is a set of names "standout|bold":

`default` does nothing, if you put it with other attributes
the other attributes will be used.

`standout` makes the text standout.

`bold` makes the text bold.

`reverse` reverses the text colors.

`underline` underlines the text.

`italic` makes the text italic (not supported on all ncurses versions).

`blink` makes the text blink.

@h2 Format Strings

Format strings control display of tracks in library, playlist and play queue
views.

Note: *altformat_\** options are used when there are no tags available.

Special Keys:

	%a  %{artist}		@br
	%A  %{albumartist}	@br
	%l  %{album}		@br
	%D  %{discnumber}	@br
	%T  %{totaldiscs}	@br
	%n  %{tracknumber}	@br
	%X  %{play_count}	@br
	%t  %{title}		@br
	%g  %{genre}		@br
	%c  %{comment}		@br
	%y  %{date}		@br
	%d  %{duration}		@br
	%f  %{path}		@br
	%F  %{filename}		@br
	    %{albumduration}    @br
	    %{originaldate}	@br
	    %{maxdate}		@br
	    %{bpm}		@br
	    %{bitrate}		@br
	    %{codec}		@br
	    %{codec_profile}	@br
	    %{rg_track_gain}	@br
	    %{rg_track_peak}	@br
	    %{rg_album_gain}	@br
	    %{rg_album_peak}	@br
	    %{arranger}		@br
	    %{composer}		@br
	    %{conductor}	@br
	    %{lyricist}		@br
	    %{performer}	@br
	    %{remixer}		@br
	    %{label}		@br
	    %{publisher}	@br
	    %{work}		@br
	    %{opus}		@br
	    %{partnumber}	@br
	    %{part}		@br
	    %{subtitle}		@br
	    %{media}		@br
	%!
		prior text is of lower importance and may be shortened if needed (use at most once)
	%=
		start align right (use at most once)
	%%
		literal *%*
	%?
		literal *?*

You can use printf style formatting (width, alignment, padding). As an
extension, the width can have a %-suffix, to specify a percentage of the
terminal width. @br
To see current value of an option type *:set option=<TAB>*.

Note: With %{bitrate}, you'll have to append the unit yourself, as mentioned
in the example below.

You can use conditional operator *%{?CONDITION?A[?B]}*.
CONDITION has the same syntax as `filters`, except for unsupported short and
simple expressions and supported keys comparison (e.g. artist=albumartist).
Its keys are:
	format strings' special keys @br
	configuration options @br
	keyword *stream* [boolean] (returns true if track is a stream) @br
	keyword *va* [boolean] (returns true if track's album is compilation)
Else part can be skipped. A and B can contain string literals in *"* or *'*.
A and B can be empty.

Examples:

	@pre
	:set format_trackwin= %02n. %t %{?y?(%y)}%= %d
	:set format_current= %n. %-30t %40F (%y)%= %d
	:set format_current= %a - %l%! - %02n. %t%= %{bitrate}Kbps %g %y
	:set format_playlist= %f%= %6{rg_track_gain} dB  %8{rg_track_peak}
	:set format_playlist= %-25%a %-15%l %3n. %t%= %y %d
	@endpre

@h2 Sort Keys

Sort option (lib_sort, pl_sort) value is space separated list of the following
sort keys:

	artist, album, title, tracknumber, play_count, discnumber, date,
	originaldate, genre, comment, albumartist, filename, filemtime, bpm,
	bitrate, codec, media, codec_profile, rg_track_gain, rg_track_peak,
	rg_album_gain, rg_album_peak

Note: Adding a '-' in front of the key will reverse the sort order.


@h1 PLUGIN OPTIONS

dsp.alsa.device
	PCM device for ALSA plugin, usually "default".

mixer.alsa.channel
	Mixer channel for ALSA Plugin, usually "pcm", "master" or "headphone".
	To see all possible values run "alsamixer" or "amixer".

mixer.alsa.device
	Mixer device for ALSA plugin, usually "default".

mixer.pulse.restore_volume
	Restore the volume at startup using PulseAudio. Otherwise, cmus sets
	the volume to 100%, which does not mix well with "flat volumes"
	feature of PA. Defaults to "1"; set to "0" to turn off.

dsp.ao.buffer_size
	The audio buffer size; defaults to 16kB, but you may want to try bigger
	values if you experience buffer under-runs.

dsp.ao.device_interface
	Device interface for libao plugin to request a specific playback
	device/sink/output. This name will be in a format determined by the
	specific driver backend.

dsp.ao.driver
	Output driver for libao plugin. Example values: "alsa09", "esd", "irix",
	"oss", "sun", "aixs", "wav".

	Note: of the file output drivers only "wav" is supported.

dsp.ao.wav_counter
	Counter used for making filename. Used only if *dsp.ao.driver* is "wav".
	For example if this is 1 and *dsp.ao.wav_dir* is "/home/user" then PCM
	data is outputted to "/home/user/01.wav". This counter is incremented
	every time playback is stopped.

	Note: You probably want to set *continue* to *false* (press *C*),
	otherwise playback is not stopped between tracks and all PCM data is
	outputted to one wav file (useful if you want to join files).c Also
	unsetting shuffle and repeat might be good idea.

dsp.ao.wav_dir
	Output directory for libao plugin; default to the home directory. Used
	only if *dsp.ao.driver* is "wav".

dsp.coreaudio.device
	Device for Core Audio output. Leave empty for default.

dsp.coreaudio.enable_hog_mode
	Set hog mode for the device. The default value is false.

dsp.coreaudio.sync_sample_rate
	Synchronize the device sample rate with the player, so no interpolation
	will be applied to the stream.

dsp.jack.server_name
	Connect to jackd with this name. Leave empty for default.

dsp.jack.resampling_quality
	The re-sampling quality. 0 is low quality but fast, 1 is medium quality,
	2 (default) is high quality but more CPU intensive. This option is only
	available if cmus was compiled with libsamplerate support.

dsp.aaudio.performance_mode (power_saving) [power_saving, none]
	Set the requested performance mode. If "power_saving", battery life is
	prioritized over low latency. If "none", battery life is balanced with
	low latency.

	This option requires restarting cmus.

dsp.aaudio.allowed_capture (all) [all, system, none]
	Specify whether the audio may or may not be captured by other apps or
	the system.

	This option is only supported on Android 10+ (API 29) and requires
	restarting cmus.

dsp.aaudio.sharing_mode (shared) [shared, exclusive]
	Request a mode for sharing the device. This is done on a best-effort
	basis, and the requested sharing mode may not be available.

	This option requires restarting cmus.

dsp.aaudio.disable_spatialization (false)
	If true, disables Android's built-in audio spatializer even if it is
	enabled for the current audio output. Note that spatialization only
	applies to audio with at least 4 channels. See
	https://developer.android.com/media/grow/spatial-audio for more details.

	This option is only supported on Android 12L+ (API 32) and requires
	restarting cmus.

input.cdio.cddb_url
	CDDB URL (default: freedb.freedb.org:8880). Uses HTTP if prefixed with
	"http://" (e.g.: http://freedb.musicbrainz.org:80/~cddb/cddb.cgi). Set
	to an empty string to disable CDDB lookup completely.

input.\*.priority
	Sets the priority of the input plugin. If multiple plugins can play a
	file, the plugin with the higher priority is chosen. If the priority is
	0, the plugin is disabled.

dsp.oss.device
	PCM device for OSS plugin, usually /dev/dsp.

mixer.oss.channel
	Mixer channel for OSS Plugin, "pcm" or "master".

mixer.oss.device
	Mixer device for OSS plugin, usually /dev/mixer.

dsp.roar.server
	Address of RoarAudio server. Defaults to internal defaults.
	Can be UNIX, TCP/IP or DECnet address.

dsp.roar.role [music, background_music, ...]
	Role for stream. May be used by the server to apply additional
	defaults.

dsp.sun.device
	PCM device for Sun plugin, usually /dev/audio.

mixer.sun.channel
	Mixer channel for Sun Plugin, usually "master".

mixer.sun.device
	Mixer device for Sun plugin, usually /dev/mixer.

@h1 PLAYING AUDIO DISCS

If the *cdio* input plugin is enabled, CDs and CD images can be played by
setting the *device* option to a device file (e.g. /dev/cdrom) or an image file
(e.g. ~/cd.cue). Then, add a new track using the CDDA URL scheme:

	:add cdda://2

To add the entire disc, use cdda:// (without track number). This only works for
audio discs, not images. Adding track ranges is also possible (cdda://1-3).

To add images without changing the device option, include the image path in the
URL:

	:add cdda:///path/to/cd.cue/2-5

The metadata will be read from CD-Text, and if not available, looked up from
a CDDB server (see *input.cdio.cddb_url*).


@h1 FILTERS

Filters are used mostly for filtering contents of library views (1 & 2).
Filters do not change the actual library content, i.e. the *:save* command will
still save all tracks to playlist file whether they are visible or not.

@h2 Types

There are three types of filter expressions, each offering more expressiveness:

	@li *simple*
	`e.g.` beatles

	@li *short*
	`e.g.` ~a beatles (!~y1960-1965 | ~d>600)

	@li *long*
	`e.g.` artist="\*beatles\*"&album="R\*"

Simple expressions are only available using *live-filter*. For other filter
commands the type is auto-detected, so both short and long expressions can be
used.

Long expressions are lists of built-in filters or user defined filters separated
with *&* (and) or *|* (or). Parenthesises can be used group subexpressions and
*!* negates result of the expression following it. The same is true for short
expressions, but they can only consist of built-in filters. Also, (and)-grouping
is done implicitly.

@h2 Strings

@li long
*filename*, *artist*, *albumartist*, *album*, *title*, *genre*, *comment*,
*codec*, *codec_profile*, *media*
@br
Comparators: *=* and *!=* (not equal)

@li short
*~f*, *~a*, *~A*, *~l*, *~t*, *~g*, *~c*
@br
Comparators: none

@h2 Integers

@li long
*discnumber*, *tracknumber*, *date* (year), *originaldate* (year), *duration*
(seconds), *bitrate*
@br
Comparators: *<*, *<=*, *=*, *>=*, *>*, *!=*

@li short
*~D*, *~n*, *~y*, *~d*
@br
Comparators: *<*, *>*
@br
Ranges: *a-b* (>=a&<=b), *-b* (<=b), *a-* (>=a)

@h2 Booleans

*tag* (true if track has tags), *stream* (true if track is a stream)
@br
For short expressions: *~T* and *~s*

@h2 Defining Filters

Filters can be defined with the *fset* command. User defined filters appear in
the filters view (6).

Create a new filter which name is *ogg* and value *filename="\*.ogg"*
	:fset ogg=filename="\*.ogg"

Filter ogg and mp3 files from the 90s. Note the use of user defined filter
*ogg*.
	:fset 90s-ogg-mp3=date>=1990&date<2000&(ogg|filename="\*.mp3")

@h2 Activating Filters

*factivate* changes the visible contents of the library (views 1-2).

Activate user defined filters *ogg* and *missing-tags*
	:factivate ogg missing-tags

Like above but negate value of *ogg* filter.
	:factivate !ogg missing-tags

Alternatively, you can filters by pressing *space* in view 6, then activate them
by pressing *enter*.

@h2 Throw-away Filters

The *live-filter* and *filter* commands are useful when you want to use a filter
without saving it. It changes the visible contents of the library (views 1-2).
*filter* unactivates all filters in the filters view, while *live-filter* is
applied in addition to all currently activated filters. It persists even after
leaving command mode.

Filter all rock (anything with *rock* in genre tag) music from 80s-
	:filter date>=1980&genre="\*rock\*"
	@br
	:filter ~y1980-~grock

Filter all artists/albums/titles containing "sleepwalking"
	:live-filter sleepwalking

@h2 Selecting Tracks Matching a Filter

Mark (select) all tracks with duration less than 2 minutes
	:mark duration<120

Mark (select) all tracks which have been played at least once
	:mark play_count>=1

These commands work in views 2-4.


@h1 FILES

cmus reads its configuration from 3 different places in the following order:

`$XDG_CONFIG_HOME/cmus/autosave`
	This file is automatically created and overwritten by cmus on exit, so
	it should not be modified by hand.

`/usr/share/cmus/rc`
	This file contains the default configuration.

	If the autosave file did exist, this file is read instead.

`$XDG_CONFIG_HOME/cmus/rc`
	This file is the static configuration file.

	This file is read immediately after the autosave file, and is never
	modified by cmus. You can override auto-saved settings in this file.
	This file is not limited to options; it can contain other commands too.

@h2 Color Schemes

Color schemes (\*.theme) are located in `/usr/share/cmus` or
`$XDG_CONFIG_HOME/cmus`. You can switch them using the *:colorscheme* command
with the basename of the theme file.

Note: Colors are not automatically updated when the theme file changes since
they are saved in the autosave file.

@h2 Examples

Example status display scripts (see *status_display_program*) can be found in
`/usr/share/doc/cmus/examples`.


@h1 ENVIRONMENT

CMUS_CHARSET
	Override the character set used by cmus (default: \`locale charmap\`).

CMUS_HOME
	Override the config directory (default: $XDG_CONFIG_HOME/cmus).

CMUS_SOCKET
	Override the socket path (default: $XDG_RUNTIME_DIR/cmus-socket).

HOME
	Full path of the user's home directory.

http_proxy
	URI of the proxy to use for HTTP requests.

USER
	Name of the user running cmus.

USERNAME
	Fallback for *USER*.

@h2 Library Environment Variables

cmus supports using environment variables to allow the library, cache, and
playlists to be relocated or synced. The environment variables to use are
specified using the `pl_env_vars` configuration option, which takes effect when
exiting cmus.

A good starting point is `:set pl_env_vars=HOME`. This will allow the `.cmus`
directory to be shared between devices or users. Additional environment
variables can be appended (delimited with commas) to `pl_env_vars` to redirect
specific paths. The environment variables must contain absolute paths to be
used. The last matching directory prefix will be used.

If a file does not exist, it will be treated the same way as missing files
usually are. If the file is in the cache, it will be preserved, and an error
will be displayed upon playback. If the file is not in the cache, it will be
removed from playlists and the library. There is one special exception: if a
file is missing due to the environment variable being invalid/empty/unset, but
it is still in the cache, it will be preserved in the cache as-is, in addition
to being preserved in the library like usual.

When using `:save`/`:load` and in the on-disk library/cache/playlists, the paths
will be stored with the environment variable delimited using the character
`\\x1F`, which is the invisible ASCII unit separator.

This feature can also be used to quickly move a library to a different location
while preserving all metadata, playlists, and the play counts. To do this, set
an environment variable for each base path you want to change, set `pl_env_vars`
to the list of environment variables, restart cmus, change the environment
variables, restart cmus, unset `pl_env_vars`, then restart cmus again.

If a library using `pl_env_vars` is opened with a version of cmus not supporting
it, tracks referenced with environment variables will be forgotten. To restore
the on-disk files to be compatible with older cmus versions, just unset
`pl_env_vars`, and restart cmus. This will restore the paths for all defined
environment variables to their actual path.

It is safe to change `pl_env_vars` from outside cmus since this variable is
applied when cmus exits.

@h1 D-Bus Interface (MPRIS)

cmus provides a D-Bus interface following the Media Player Remote Interfacing Specification (MPRIS) v2:
	https://www.freedesktop.org/wiki/Specifications/mpris-spec/

It exposes the `/org/mpris/MediaPlayer2` object path with the interfaces
`org.mpris.MediaPlayer2` and `org.mpris.MediaPlayer2.Player`.
The unique bus name is `org.mpris.MediaPlayer2.cmus`.

Metadata fields follow the naming convention of the specification:
	https://www.freedesktop.org/wiki/Specifications/mpris-spec/metadata/
Additionally, the `cmus:stream_title` field is exposed if appropriate.

@h1 BUGS

The file exists only if you configured cmus with the maximum debug level
(*./configure DEBUG=2*).

After a crash, the last lines of `~/cmus-debug.txt` may contain useful
information.  

Feature requests and bug reports should go to the GitHub issue tracker:
	https://github.com/cmus/cmus/issues


@h1 SEE ALSO

*cmus-tutorial*(7), *cmus-remote*(1)


@h1 AUTHORS

cmus was mainly written by Timo Hirvonen <tihirvon\@gmail.com>. Other
contributors are listed in the `AUTHORS` file.

This man page was written by Frank Terbeck <ft\@bewatermyfriend.org>,
Timo Hirvonen <tihirvon\@gmail.com>, Clay Barnes <clay.barnes\@gmail.com>, and
Patrick Gaskin <patrick\@pgaskin.net>.