code: func getResourcesAndSelector(args []string) (resources []string, selector *metav1.LabelSelector, err error) {
  	if len(args) == 0 {
  		return []string{}, nil, nil
  	}
  	resources = args[:len(args)-1]
  	selector, err = metav1.ParseToLabelSelector(args[len(args)-1])
  	return resources, selector, err
  }
docs: // getResourcesAndSelector retrieves resources and the selector expression from the given args (assuming selectors the last arg)