<commit_before>#!/usr/bin/env ruby

environment = ARGV[0]
ARGV[0] = nil

ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../DeployGemfile', __FILE__)
load Gem.bin_path('bundler', 'bundle')

require 'aws-sdk'

AWS.config(
  access_key_id: ENV["#{environment.upcase}_AWS_ACCESS_KEY_ID"],
  secret_access_key: ENV["#{environment.upcase}_AWS_SECRET_ACCESS_KEY"]
)

config = {
  staging: {
    stack_id: "db959bc5-7818-4a1c-8b9f-04d26ce6dae5",
    layer_id: "c1f6b265-27b0-4bc6-b8eb-bb4d72a80179",
    app_id: "914e9d2b-8656-4780-bb92-998a78e3c0ed"
  }
}

client = AWS::OpsWorks::Client.new

# get the instances we want to deploy to
i = client.describe_instances(
  layer_id: layer
)
<commit_msg>... this is what I get for a bad copy paste job<commit_after>#!/usr/bin/env ruby

environment = ARGV[0]
ARGV[0] = nil

ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../DeployGemfile', __FILE__)
load Gem.bin_path('bundler', 'bundle')

require 'aws-sdk'

AWS.config(
  access_key_id: ENV["#{environment.upcase}_AWS_ACCESS_KEY_ID"],
  secret_access_key: ENV["#{environment.upcase}_AWS_SECRET_ACCESS_KEY"]
)

config = {
  staging: {
    stack_id: "db959bc5-7818-4a1c-8b9f-04d26ce6dae5",
    layer_id: "c1f6b265-27b0-4bc6-b8eb-bb4d72a80179",
    app_id: "914e9d2b-8656-4780-bb92-998a78e3c0ed"
  }
}

client = AWS::OpsWorks::Client.new

# get the instances we want to deploy to
i = client.describe_instances(
  layer_id: config[environment.to_sym][:layer_id]
)

{'fraction_non_alphanumeric': 0.1542185338865837, 'fraction_numerical': 0.08437067773167359, 'mean_word_length': 5.029166666666667, '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': '52235', 'n_tokens_mistral': 694, 'n_tokens_neox': 645, 'n_words': 93}