This file is indexed.

/usr/share/anyremote/cfg-data/Server-mode/clementine.cfg is in anyremote-data 6.5-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  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
%
% anyremote configuration file for clementine (http://www.clementine-player.org/) management. (Server-mode)
% 
% Thanks Kristjan Ugrin for corrections.
%
% TODO: support DBUS 
%       http://code.google.com/p/clementine-player/wiki/MPRIS
%

% STATUS stable
% XTEST no
% ENV no
% SOUND mixer
% DEF_PLAYER   
% ALL_IN_ONE 
% MEDIACENTER audio

GuiAppName=Clementine
GuiAppBinary=clementine
GuiAppRun=echo 'A=`ps -ef|grep clementine|grep -v grep|grep -v edit`; if [ "x$A" = "x" ]; then echo NOK; else echo OK; fi'|sh -s
GuiAppIcon=clementine.png
GuiAppType=Application
GuiAppProtocols=Server
GuiAppDesc=A music player.

[Protocol]=Server

(Init)=\
	Include($(CfgDir)/Utils/aliases-server.cfg);\
	Macro(SETUP_DEFAULT_MIXER);\
	Make(var,player_name,by_value,Clementine);\
	Include($(CfgDir)/Utils/aliases-server-player.cfg);\
	Make(var,cover_size,by_value,);\
	Make(var,clementine_layout,\
	     V=`$(CfgDir)/Utils/registry.sh $(TmpDir) get clementine_layout`;\
	     if [ "x$V" = "x" ]; then echo "5x1"; else echo $V; fi);

(Exit)=\
	Exec($(CfgDir)/Utils/registry.sh $(TmpDir) set clementine_layout $(clementine_layout));

(Connect)=\
	Make(mode,clementine_$(clementine_layout));

[Mode]=clementine_general

PLAY=\
	Exec(clementine -t);\
	Macro(CLEMENTINE_TITLE,sleep 1;echo 0);\
	Timer(CLEMENTINE_TITLE,$(UpdateTimeout),0);

RWD=\
	Exec(clementine --seek-by -10);

FF=\
	Exec(clementine --seek-by +10);

PREV=\
	Exec(clementine -r);\
	Macro(CLEMENTINE_TITLE);

STOP=\
	Timer(CLEMENTINE_TITLE,cancel);\
	Exec(clementine -s);\
	Set(title,);\
	Set(status,);

NEXT=\
	Exec(clementine -f);\
	Macro(CLEMENTINE_TITLE);

PAUSE=\
	Exec(clementine -u);

RUN_IF_NEED=\
	Exec($(CfgDir)/Utils/run-or-switch-to.sh clementine);
	
RUN_OR_QUIT=\
	Exec(P=`ps auxc|grep clementine`;\
	     if [ "x$P" = "x" ]; then clementine & else killall clementine; fi);
	
APP_QUIT=\
	Exec(killall clementine);
	
CLEMENTINE_TITLE_GENERAL=\
	Make(var,clementine_index,qdbus org.mpris.clementine /TrackList org.freedesktop.MediaPlayer.GetCurrentTrack);\
	Make(var,clementine_artist,qdbus org.mpris.clementine /TrackList org.freedesktop.MediaPlayer.GetMetadata $(clementine_index)|grep artist|sed "s/artist: //");\
	Make(var,clementine_album,qdbus org.mpris.clementine /TrackList org.freedesktop.MediaPlayer.GetMetadata $(clementine_index)|grep album|sed "s/album: //");\
	Make(var,clementine_song,qdbus org.mpris.clementine /TrackList org.freedesktop.MediaPlayer.GetMetadata $(clementine_index)|grep title|sed "s/title: //");\
	Set(title,$(clementine_artist) - $(clementine_album));\
	Set(status,$(clementine_song));
	
Shuffle=\
	Exec(P=`qdbus org.mpris.clementine /org/mpris/MediaPlayer2 Shuffle`; \
		if [ "x$P" = "xtrue" ]; \
		then \
		    qdbus org.mpris.clementine /org/mpris/MediaPlayer2 Shuffle false & \
		else \
		    qdbus org.mpris.clementine /org/mpris/MediaPlayer2 Shuffle true & \
		fi);

Repeat=\
	Exec(P=`qdbus org.mpris.clementine /org/mpris/MediaPlayer2 LoopStatus`; \
		if [ "x$P" = "xNone" ]; \
		then \
		    qdbus org.mpris.clementine /org/mpris/MediaPlayer2 LoopStatus Track & \
		else \
		    qdbus org.mpris.clementine /org/mpris/MediaPlayer2 LoopStatus None & \
		fi);
Playlist=\
	Make(mode,clementine_playlist);

APP_PLAY_STATUS=\
	Make(var,clementine_status,qdbus org.mpris.clementine /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.PlaybackStatus);\
	Make(var,app_status,if [ "x$(clementine_status)" = "xPlaying" ]; then echo playing; else echo paused; fi);

Layout 3x4=\
	Make(mode,clementine_3x4);

Layout 7x1=\
	Make(mode,clementine_7x1);

Layout 5x1=\
	Make(mode,clementine_5x1);

[ModeEnd]

[Mode]=clementine_3x4 : clementine_general,default_player

% (EnterMode) by Utils/aliases-server-player.cfg

APP_MENU=\
	Set(menu,replace,Playlist,Shuffle,Repeat,Layout 5x1,Layout 7x1,PowerMgmt);\
	Macro(ALLIN1MENU);\
	Macro(MEDIACENTER_MENU);

APP_POST_SETUP=\
	Make(var,clementine_layout,by_value,3x4);

% PowerMgmt by Utils/aliases-server.cfg
	
% Volume control and 0-9,*,# assignments by Utils/aliases-server-player.cfg
%1=Exec(clementine --volume-down)
%2=Macro(DEFAULT_TOGGLE_MUTE)
%3=Exec(clementine --volume-up)

CLEMENTINE_TITLE=\
    Make(var,clementine_status,qdbus org.mpris.clementine /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.PlaybackStatus);\
	Macro(DO_CLEMENTINE_TITLE,if [ "x$(clementine_status)" = "xPlaying" ]; then echo 0; else echo 1; fi);

DO_CLEMENTINE_TITLE=\
	Macro(CLEMENTINE_TITLE_GENERAL);

[ModeEnd]

[Mode]=clementine_cover

CLEMENTINE_TITLE=\
    Make(var,clementine_status,qdbus org.mpris.clementine /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.PlaybackStatus);\
	Macro(DO_CLEMENTINE_TITLE,if [ "x$(clementine_status)" = "xPlaying" ]; then echo 0; else echo 1; fi);

DO_CLEMENTINE_TITLE=\
	Macro(CLEMENTINE_TITLE_GENERAL);\
	Macro(APP_COVER, if [ "x$(cover_size)" = "x" ]; then echo 1; else echo 0; fi);

APP_COVER=\
	Make(var,media_file,\
	     qdbus org.mpris.clementine /TrackList org.freedesktop.MediaPlayer.GetMetadata $(clementine_index)|grep location|\
	     sed "s/^[^/]*\//\//;s/\/\/\//\//;s/'/'\\\''/g;s/\//\'\/\'/g;s/$/\'/g;s/^'\//\//");\
	Macro(DEFAULT_COVER);

[ModeEnd]

[Mode]=clementine_7x1 : clementine_general,default_player_7x1,clementine_cover

APP_MENU=\
	Set(menu,replace,Playlist,Mute,Shuffle,Repeat,Next Cover,Previous Cover,Update Cover,Layout 3x4,Layout 5x1,Help,PowerMgmt);\
	Macro(ALLIN1MENU);\
	Macro(MEDIACENTER_MENU);

APP_POST_SETUP=\
	Make(var,clementine_layout,by_value,7x1);

[ModeEnd]

[Mode]=clementine_5x1 : clementine_general,default_player_5x1,clementine_cover

APP_MENU=\
	Set(menu,replace,Playlist,Mute,Shuffle,Repeat,Next Cover,Previous Cover,Update Cover,Layout 3x4,Layout 7x1,Help,PowerMgmt);\
	Macro(ALLIN1MENU);\
	Macro(MEDIACENTER_MENU);

APP_POST_SETUP=\
	Make(var,clementine_layout,by_value,5x1);

APP_TITLE=\
	Macro(CLEMENTINE_TITLE);

% no timer
PLAY=\
	Exec(clementine -t);\
	Macro(CLEMENTINE_TITLE,sleep 1;echo 0);

[ModeEnd]

[Mode]=clementine_nobutton

% bug-prone :)
1=Make(mode,clementine_$(clementine_layout));	
2=Make(mode,clementine_$(clementine_layout));	
3=Make(mode,clementine_$(clementine_layout));	
4=Make(mode,clementine_$(clementine_layout));	
5=Make(mode,clementine_$(clementine_layout));	
6=Make(mode,clementine_$(clementine_layout));	
7=Make(mode,clementine_$(clementine_layout));	
8=Make(mode,clementine_$(clementine_layout));	
9=Make(mode,clementine_$(clementine_layout));	
*=Make(mode,clementine_$(clementine_layout));	
0=Make(mode,clementine_$(clementine_layout));	
#=Make(mode,clementine_$(clementine_layout));	

[ModeEnd]

[Mode]=clementine_playlist : clementine_nobutton

(EnterMode)=\
	ExecAndSet(list,replace,Playlist,$(CfgDir)/Utils/getPlayList.sh org.mpris.clementine);\
  	ExecAndSet(list,select,expr 1 + `qdbus org.mpris.clementine  /TrackList GetCurrentTrack`);\
	Set(menu,replace,Choose,Delete);
	
Push($$)=\
	Macro(Choose($$))
	
Choose($$)=\
	Exec(qdbus org.mpris.clementine /TrackList PlayTrack `expr $(Index) - 1`);

Delete($$)=\
	Exec(qdbus org.mpris.clementine /TrackList DelTrack `expr $(Index) - 1`);

Back($$)=\
	Set(list,close);\
	Make(mode,clementine_$(clementine_layout));

[ModeEnd]

%qdbus org.mpris.clementine /TrackList org.freedesktop.MediaPlayer.GetCurrentTrack
%qdbus org.mpris.clementine /TrackList org.freedesktop.MediaPlayer.GetMetadata
%qdbus org.mpris.MediaPlayer2.clementine  /TrackList org.freedesktop.MediaPlayer.AddTrack
%qdbus org.mpris.MediaPlayer2.clementine  /TrackList  org.freedesktop.MediaPlayer.DelTrack

[End]