<commit_before>package main

import (
	"fmt"
	"github.com/Symantec/Dominator/imagepublishers/amipublisher"
	libjson "github.com/Symantec/Dominator/lib/json"
	"log"
	"os"
)

func listUnpackersSubcommand(args []string, logger *log.Logger) {
	err := listUnpackers(logger)
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error preparing unpackers: %s\n", err)
		os.Exit(1)
	}
	os.Exit(0)
}

func listUnpackers(logger *log.Logger) error {
	results, err := amipublisher.ListUnpackers(targets, skipTargets,
		*unpackerName, logger)
	if err != nil {
		return err
	}
	return libjson.WriteWithIndent(os.Stdout, "    ", results)
}
<commit_msg>Fix error message in ami-publisher list-unpackers subcommand.<commit_after>package main

import (
	"fmt"
	"github.com/Symantec/Dominator/imagepublishers/amipublisher"
	libjson "github.com/Symantec/Dominator/lib/json"
	"log"
	"os"
)

func listUnpackersSubcommand(args []string, logger *log.Logger) {
	err := listUnpackers(logger)
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error listing unpackers: %s\n", err)
		os.Exit(1)
	}
	os.Exit(0)
}

func listUnpackers(logger *log.Logger) error {
	results, err := amipublisher.ListUnpackers(targets, skipTargets,
		*unpackerName, logger)
	if err != nil {
		return err
	}
	return libjson.WriteWithIndent(os.Stdout, "    ", results)
}

{'fraction_non_alphanumeric': 0.13615384615384615, 'fraction_numerical': 0.003076923076923077, 'mean_word_length': 4.756637168141593, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6520301', 'n_tokens_mistral': 518, 'n_tokens_neox': 509, 'n_words': 96}