ACC SHELL

Path : /usr/share/YaST2/modules/
File Upload :
Current File : //usr/share/YaST2/modules/SystemFilesCopy.ybc

YaST bytecode 1.4.0SystemFilesCopySystemFilesCopy.ycp	Directory	FileUtilsStringInstallationProductFeaturesStageInstDatacopy_files_to_installed_system		already_initialized
inst_sys_tmp_directory	tmp_mount_directory	counter_max
tmp_archive_counterCreateDirectoryIfMissing		
InitializeCopyFilesToTemp			CopyFilesToSystem	AdjustDirectoryPath		CopyFilesFromDirToDir		SaveInstSysContentGetUseControlFileDefSetUseControlFileDefGetCopySystemFilesSetCopySystemFiles>create_directory		partition		filenames	copy_to	extract_to_dir	bl	new_valueznew_copy_files3WFMExecute3SCRExecute0installation3	Directoryvardir	3	FileUtilsExists	IsDirectory	3StringQuote		3Installationdestdir	3ProductFeatures
GetSection		3Stageinitial3InstDataadditional_copy_filescopy_files_use_control_file$#	$%	$'
$)$,
$.
%>(@
4@(B
4B,C	
y2milestone	
Directory %1 already exists
-D
4Fnew_dir	,G	
	y2warning	
Path %1 is not a directory
$H
)J&&
4J&K-&L
+			
x&M

-P
4T,USCR::Execute
.target.mkdir
(W
4W,X	
y2milestone	
Directory %1 created
-Y
4[,\	
y2error	
Cannot create path %1
-]%h(i	-i&k
&/tmp/tmp_dir_for_SystemFilesCopy_files&l&/tmp/tmp_dir_for_SystemFilesCopy_mount(n||
4n,o	
y2error	
'Cannot create one of needed directories-p&t	-u%archive_name	ret
archive_files	command	cmd_run(!4,	
y2error	
Cannot initialize!-&
+
$		
sformat		
%1/_inst_archive_%2.tgz

,	
y2milestone	
=Copying from '%1' files %2 to '%3'. Files will appear in '%4'


,	
y2milestone	
Mounting %1 to %2
(!SCR::Execute
.target.mount
-o ro4,	
y2error	
Mounting failed!-$$,		foreachfilename	
(			substring		/&			substring		&+			+			+			 ''$		
sformat		
;cd '%1'; tar --recursion -zcvf '%2' --ignore-failed-read %3$SCR::Execute.target.bash_output(exit4,	
y2error	
,Problem during archivation: %1, command >%2<&4,	
y2milestone	
Archived: %1,	
y2milestone	
Umounting %1
(!SCR::Execute.target.umount4,	
	y2warning	
Umounting failed!&			add
-%ret(!	4,	
y2error	
-CopyFilesToTemp() needs to be called first...-$,		foreacharchive_to_extract	archive_name	where_to_extract	command	cmd_run$
	$
	(||

4,	
y2error	
'Something is wrong with the archive: %1&&
		
sformat		
%1%2

$
		
sformat		
Nmkdir -p '%1'; cd '%1'; tar --preserve-permissions --preserve-order -xvzf '%2'

$
SCR::Execute.target.bash_output
(
exit4,	
y2error	
6Problem during extracting an archive: %1, command >%2<

&4,	
y2milestone	
Extracted: %1 into %2

-%directory_path	
dir_path_list	$			splitstring			
/&			filterone_dir	&
			mergestring			/&
		
sformat		
/%1/
-
%dir_from	dir_to	cmd	cmd_run$		
sformat		
"mkdir -p '%2' && cp -ar '%1.' '%2'

$WFM::Execute.local.bash_output(exit4,	
y2error	
Command %1 failed %2-4,	
y2milestone	
Command >%1< succeeded-%globals_features	save_content		( !4 ,!	
y2error	
6This function can be called in the initial stage only!-"$%
globals('
4',(	
	y2warning	
No <globals> defined-)(*
save_instsys_content		4*,+	
y2milestone	
No items to copy from inst-sys-,$/
		
save_instsys_content(1
41,2	
y2error	
 Cannot save inst-sys content: %1
save_instsys_content-3,6	
y2milestone	
Save inst-sys content: %1
,7				foreach	copy_item		
dir_from	dir_to	position_str_in_str	(8instsys_directory	48,9	
y2error	
Error: %1 is not definedinstsys_directory-:(;system_directory	4;,<	
y2error	
Error: %1 is not definedsystem_directory-=$@		
sformat		
/%1/instsys_directory	$A		
sformat		
/%1/%2/system_directory	&C&D(F4F,G	
y2error	
1Dir 'from (%1)' and 'to (%2)' mustn't be the same-H$M		search		(N&&4N,O	
y2error	
4Cannot copy a directory content to itself (%1 -> %2)-P,S-V%b-c	%l(m
4m,n	
y2error	
Wrong value: %1
-o&r	
,s	
y2milestone	
1Using copy_to_system from control file set to: %1
%z-{	%use_item&		$,foreach
one_copy_item
copy_to_dir	mandatory_files	optional_files	$
	tostring		copy_to_dir(||

4,	
y2error	
&(string) 'copy_to_dir' must be defined&$
mandatory_files	(||

	4,	
y2error	
1(list <string>) 'mandatory_files' must be defined&$
optional_files	(
4,	
y2error	
1(list <string>) 'optional_files' wrong definition&(4&	add	

ACC SHELL 2018