parameters: (self, x, tar)
docstring: Adds a file to the tar archive. Symlinks are not verified.
  
  		:param x: file path
  		:param tar: tar file object
docstring_summary: Adds a file to the tar archive. Symlinks are not verified.
docstring_tokens: Adds a file to the tar archive . Symlinks are not verified .
function: def add_tar_file(self, x, tar):
  		"""
  		Adds a file to the tar archive. Symlinks are not verified.
  
  		:param x: file path
  		:param tar: tar file object
  		"""
  		p = self.get_tar_path(x)
  		tinfo = tar.gettarinfo(name=p, arcname=self.get_tar_prefix() + '/' + x.path_from(self.base_path))
  		tinfo.uid   = 0
  		tinfo.gid   = 0
  		tinfo.uname = 'root'
  		tinfo.gname = 'root'
  
  		if os.path.isfile(p):
  			with open(p, 'rb') as f:
  				tar.addfile(tinfo, fileobj=f)
  		else:
  			tar.addfile(tinfo)
function_tokens: def add_tar_file ( self , x , tar ) : p = self . get_tar_path ( x ) tinfo = tar . gettarinfo ( name = p , arcname = self . get_tar_prefix ( ) + '/' + x . path_from ( self . base_path ) ) tinfo . uid = 0 tinfo . gid = 0 tinfo . uname = 'root' tinfo . gname = 'root' if os . path . isfile ( p ) : with open ( p , 'rb' ) as f : tar . addfile ( tinfo , fileobj = f ) else : tar . addfile ( tinfo )