ImpUnit 0.2.0 → 0.2.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/lib/ImpUnit/version.rb +1 -1
  3. data/lib/ImpUnit.rb +158 -123
  4. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 2fb73dd84cd98982678f14e7739c897362c2948fc0005c4383b02c0d671eb6ae
4
- data.tar.gz: 9e356b01c4dd236ba8975076a31925ae93bf167373fd16cace8ce5c8761edc21
3
+ metadata.gz: 2c224c84d73dfa3da3084615e9b1b3e4446dda9912d020e0dcbea40b1b040227
4
+ data.tar.gz: 7b34acb44943729d6772ab3cb9d21906e2a003ed249ec03b95f473752c49b5e7
5
5
  SHA512:
6
- metadata.gz: 0ef7a5913109fa04f213bf5f0f1074e73c4741c17f357d72efae240f9ba115a502698c083c69b2f6b467e0052438725297af37d51140fe51eb7c24e163f94127
7
- data.tar.gz: a0ae436903b6577d43c81ff5eb7fd6d0a1367f0b58acff42d15aecb48f0e07d88673365a6acd2c5db818c1c3f6b37cd2398966cabc6f93da6998fc1f6ba64c58
6
+ metadata.gz: 9f628da9b3073c7430e63db2f95da83226e4415af283208c2b229f0ffdac59c837152c8638edd15636e6566fa485217ef3a7cfebf06df57bd37fff5ebac7c126
7
+ data.tar.gz: d2ebd7ac4d9fc050fe9f872f39b1e81b9482897c176b5843ed653ce3b0386ab973de76c73f655873a4cebfd7afc27214ab33962e75b3b0d52a800423f57bd0d2
@@ -1,3 +1,3 @@
1
1
  module ImpUnit
2
- VERSION = "0.2.0"
2
+ VERSION = "0.2.4"
3
3
  end
data/lib/ImpUnit.rb CHANGED
@@ -5,6 +5,9 @@ module ImpUnit
5
5
 
6
6
  # class options
7
7
  # def self.imp_choose
8
+ # require "decisiontree"
9
+
10
+
8
11
  # end
9
12
 
10
13
  # def self.manual
@@ -464,14 +467,14 @@ end"
464
467
  local_name = File.read("data/usr_identity/local_name.txt").strip.to_s
465
468
 
466
469
  # Create XML tags
467
- salut = " <salut>Hello</salut>"
468
- ejento = " <ejento>#{agent_name}</ejento>"
469
- rikusuto = " <rikusuto>#{request_type}</rikusuto>"
470
- atemu = " <atemu>#{item}</atemu>"
471
- nitote = " <nitote>for</nitote>"
472
- kara = " <kara>from</kara>"
473
- yuza = " <yuza>#{user_name}</yuza>"
474
- lieu = " <lieu>#{local_name}</lieu>"
470
+ salut = "Hello"
471
+ ejento = " #{agent_name}"
472
+ rikusuto = " #{request_type}"
473
+ atemu = " #{item}"
474
+ nitote = " for"
475
+ kara = " from"
476
+ yuza = " #{user_name}"
477
+ lieu = " #{local_name}?"
475
478
 
476
479
  conjucate = [nitote, kara]
477
480
  consign = conjucate.sample
@@ -479,81 +482,88 @@ end"
479
482
  user_location = [yuza, lieu]
480
483
  usign = user_location[0]
481
484
 
482
- open("index.xml", "w") { |f|
483
- f.puts xml_header
484
- f.puts topic_header
485
- f.puts salut
486
- f.puts ejento
487
- f.puts rikusuto
488
- f.puts atemu
489
- f.puts consign
490
- f.puts usign
491
- f.puts topic_bottom
485
+ system("date +'%Y-%d-%m' > date.txt")
486
+
487
+ date = File.read("date.txt").strip.to_s
488
+
489
+ open("#{date}-update.md", "w") { |f|
490
+ f.puts "---"
491
+ f.puts "title: '#{date} Update'"
492
+ f.puts "layout: post"
493
+ f.puts "---"
494
+ f.puts "#{salut} #{ejento} #{rikusuto} #{atemu} #{consign} #{usign}"
492
495
  }
493
496
  end
494
497
  end
495
498
 
496
- #class BotWings
497
- #def self.reset_evo
498
- #reset_usr_input = 0
499
+ class BotWings
500
+ def self.reset_evo
501
+ reset_usr_input = 0
499
502
 
500
- #open("data/number/input.txt", "w") { |f|
501
- #f.puts reset_usr_input
502
- #}
503
- #end
503
+ open("data/number/input.txt", "w") { |f|
504
+ f.puts reset_usr_input
505
+ }
506
+ end
504
507
 
505
- #def self.use_form
506
- #system("tts 'Form status: Suitable...', 'en'")
508
+ def self.use_form
509
+ puts "Form status: Suitable..."
507
510
 
508
- #sleep(3)
511
+ sleep(3)
509
512
 
510
- ## Detect bot form
511
- ## bot_choice = File.read("data/bot_input/input.txt").strip.to_i
512
- ## bot_wings = File.readlines("data/bot_shape/wings.txt")
513
+ # Detect bot form
514
+ # bot_choice = File.read("data/bot_input/input.txt").strip.to_i
515
+ # bot_wings = File.readlines("data/bot_shape/wings.txt")
513
516
 
514
- ## Form conditional
515
- ## if bot form is decision tree
516
- ## elsif bot form is naive bayes
517
- ## elsif bot form is biometrics
518
- ## elsif bot form is "infinite learning algorithm"
517
+ # Form conditional
518
+ # if bot form is decision tree
519
+ # elsif bot form is naive bayes
520
+ # elsif bot form is biometrics
521
+ # elsif bot form is "infinite learning algorithm"
519
522
 
520
- #abort
521
- #end
523
+ abort
524
+ end
522
525
 
523
- #def self.reshape
524
- #system("clear")
526
+ def self.reshape
527
+ system("clear")
525
528
 
526
- #model_type = File.read("data/model/model_type.txt").strip
529
+ model_type = File.read("data/model/model_type.txt").strip
527
530
 
528
- #bot_choice = File.read("data/bot_input/input.txt").strip.to_i
529
- #number = File.read("data/number/input.txt").strip.to_i
531
+ bot_choice = File.read("data/bot_input/input.txt").strip.to_i
532
+ number = File.read("data/number/input.txt").strip.to_i
530
533
 
531
- #usr_wings = File.readlines("data/usr_shape/wings.txt")
532
- #bot_wings = File.readlines("data/bot_shape/wings.txt")
534
+ usr_wings = File.readlines("data/usr_shape/wings.txt")
535
+ bot_wings = File.readlines("data/bot_shape/wings.txt")
533
536
 
534
- #current_wingset = usr_wings[number]
535
- #current_botwings = bot_wings[bot_choice]
537
+ current_wingset = usr_wings[number]
538
+ current_botwings = bot_wings[bot_choice]
536
539
 
537
- #system("tts 'The user #{model_type} model is: #{current_wingset}', 'en'")
538
- #system("tts 'The bot #{model_type} model is: #{current_botwings}', 'en'")
540
+ print "The user #{model_type} model has: #{current_wingset}"
541
+ print "The bot #{model_type} model has: #{current_botwings}"
539
542
 
540
- #if current_wingset == current_botwings
541
- #use_form
542
- #else
543
- #system("tts 'Form status: Changing form...', 'en'")
543
+ if current_wingset == current_botwings
544
+ ImpUnit::BotWings.use_form
544
545
 
545
- #sleep(3)
546
+ sleep(3)
547
+ # ImpUnit::BotWings.reset_evo
548
+ else
549
+ # system("tts 'Form status: Changing form...', 'en'")
546
550
 
547
- #new_value = number + 1
551
+ puts "Form status: Changing form..."
548
552
 
549
- #open("data/number/input.txt", "w") { |f|
550
- #f.puts new_value
551
- #}
552
- #end
553
+ sleep(3)
553
554
 
554
- #Botwings::BotWings.reshape
555
- #end
556
- #end
555
+ new_value = number + 1
556
+
557
+ open("data/number/input.txt", "w") { |f|
558
+ f.puts new_value
559
+ }
560
+
561
+ ImpUnit::BotWings.reshape
562
+ end
563
+
564
+ ImpUnit::BotWings.reshape
565
+ end
566
+ end
557
567
 
558
568
  class Spices
559
569
 
@@ -667,100 +677,125 @@ end"
667
677
  end
668
678
  end
669
679
 
680
+ #module Bianca
681
+ #class SmallTalk
682
+ #def self.name
683
+ #end
684
+
685
+ #def self.pets
686
+ #end
687
+
688
+ #def self.hobbies
689
+ #end
690
+
691
+ #def self.jobs
692
+ #end
693
+
694
+ #def self.skills
695
+ #end
696
+
697
+ #def self.weather
698
+ #end
699
+
700
+ #def self.operate
701
+ #end
702
+ #end
703
+ #end
704
+
670
705
  ## Measuring the distance between objects and size of objects in space.
671
- module SpatialRelationships
672
- class Error < StandardError; end
706
+ #module SpatialRelationships
707
+ #class Error < StandardError; end
673
708
 
674
- class Static_Perimeters
709
+ #class Static_Perimeters
675
710
 
676
711
  # The objects within the space.
677
- def positive_perimeters
712
+ #def positive_perimeters
678
713
  # Base radius of static objects.
679
- base_radius = 2500
714
+ #base_radius = 2500
680
715
 
681
716
  # Specfic multipliers for Earth index based objects.
682
- base_two = 2
683
- base_fro = 4
684
- base_six = 6
685
- base_eit = 8
717
+ #base_two = 2
718
+ #base_fro = 4
719
+ #base_six = 6
720
+ #base_eit = 8
686
721
 
687
722
  # Size of specific objects.
688
- size_of_planets = base_radius ** base_fro
689
- size_of_moons = base_radius ** base_two
690
- size_of_stars = base_radius ** base_six
691
- size_of_blackholes = base_radius ** base_eit
723
+ #size_of_planets = base_radius ** base_fro
724
+ #size_of_moons = base_radius ** base_two
725
+ #size_of_stars = base_radius ** base_six
726
+ #size_of_blackholes = base_radius ** base_eit
692
727
 
693
728
  # Total output sizes of specific objects.
694
- puts "The size of the planets is #{size_of_planets} radius."; sleep(3)
695
- puts "The size of the moons is #{size_of_moons} radius."; sleep(3)
696
- puts "The size of the stars is #{size_of_stars} radius."; sleep(3)
697
- puts "The size of a blackhole is #{size_of_blackholes} radius."; sleep(3)
698
- end
729
+ #puts "The size of the planets is #{size_of_planets} radius."; sleep(3)
730
+ #puts "The size of the moons is #{size_of_moons} radius."; sleep(3)
731
+ #puts "The size of the stars is #{size_of_stars} radius."; sleep(3)
732
+ #puts "The size of a blackhole is #{size_of_blackholes} radius."; sleep(3)
733
+ #end
699
734
 
700
735
  # Space between the objects.
701
- def negative_perimeters
736
+ #def negative_perimeters
702
737
  # Base distance between objects.
703
- base_distance = 1_000_000_000
738
+ #base_distance = 1_000_000_000
704
739
 
705
740
  # Estimated divider between specific objects to base distance.
706
- space_between_planets = 43.8
707
- space_between_moons = 14.6
708
- space_between_stars = 876
709
- space_between_blackholes = 2628
741
+ #space_between_planets = 43.8
742
+ #space_between_moons = 14.6
743
+ #space_between_stars = 876
744
+ #space_between_blackholes = 2628
710
745
 
711
746
  # Minimum distance between objects.
712
- planet_distance = base_distance / space_between_planets
713
- moon_distance = base_distance / space_between_moons
714
- star_distance = base_distance / space_between_stars
715
- blackhole_distance = base_distance / space_between_blackholes
747
+ #planet_distance = base_distance / space_between_planets
748
+ #moon_distance = base_distance / space_between_moons
749
+ #star_distance = base_distance / space_between_stars
750
+ #blackhole_distance = base_distance / space_between_blackholes
716
751
 
717
752
  # Actual distance between objects
718
- actual_planets = planet_distance * 10
719
- actual_moons = moon_distance * 10
720
- actual_stars = star_distance * 10
721
- actual_blackholes = blackhole_distance * 10
753
+ #actual_planets = planet_distance * 10
754
+ #actual_moons = moon_distance * 10
755
+ #actual_stars = star_distance * 10
756
+ #actual_blackholes = blackhole_distance * 10
722
757
 
723
758
  # The output results of distance between objects.
724
- puts "The distance between planets is #{actual_planets} miles."; sleep(3)
725
- puts "The distance between moons is #{actual_moons} miles."; sleep(3)
726
- puts "The distance between stars is #{actual_stars} miles."; sleep(3)
727
- puts "The distance between blackholes is #{actual_blackholes} miles."; sleep(3)
728
- end
759
+ #puts "The distance between planets is #{actual_planets} miles."; sleep(3)
760
+ #puts "The distance between moons is #{actual_moons} miles."; sleep(3)
761
+ #puts "The distance between stars is #{actual_stars} miles."; sleep(3)
762
+ #puts "The distance between blackholes is #{actual_blackholes} miles."; sleep(3)
763
+ #end
729
764
 
730
- end
765
+ #end
731
766
 
732
767
  # Changing perimeters
733
- class Dynamic_Perimeters
768
+ #class Dynamic_Perimeters
734
769
 
735
770
  # The objects within the space.
736
- def positive_perimeters
737
- spaceship = File.read("data/dynamic/positive_perimenters/spaceship_size.txt").strip.to_i
738
- space_station = spaceship * 200
739
- satalite = space_station / 10
771
+ #def positive_perimeters
772
+ #spaceship = File.read("data/dynamic/positive_perimenters/spaceship_size.txt").strip.to_i
773
+ #space_station = spaceship * 200
774
+ #satalite = space_station / 10
740
775
 
741
- puts "The total size of the space shuttle is #{spaceship} feet."; sleep(3)
742
- puts "The total size of the space station is #{space_station} feet."; sleep(3)
743
- puts "The total size of the satalite is #{satalite} feet."; sleep(3)
744
- end
776
+ #puts "The total size of the space shuttle is #{spaceship} feet."; sleep(3)
777
+ #puts "The total size of the space station is #{space_station} feet."; sleep(3)
778
+ #puts "The total size of the satalite is #{satalite} feet."; sleep(3)
779
+ #end
745
780
 
746
781
  # Space between the objects.
747
- def negative_perimeters
748
- base_multiplier = 10
782
+ #def negative_perimeters
783
+ #base_multiplier = 10
749
784
 
750
785
  # Minimum space between objects.
751
- space_between_spaceships = File.read("data/dynamic/negative_perimeters/space_between_spaceships.txt").strip.to_i
752
- space_between_station = File.read("data/dynamic/negative_perimeters/space_between_station.txt").strip.to_i
753
- space_between_satalite = File.read("data/dynamic/negative_perimeters/space_between_satalite.txt").strip.to_i
786
+ #space_between_spaceships = File.read("data/dynamic/negative_perimeters/space_between_spaceships.txt").strip.to_i
787
+ #space_between_station = File.read("data/dynamic/negative_perimeters/space_between_station.txt").strip.to_i
788
+ #space_between_satalite = File.read("data/dynamic/negative_perimeters/space_between_satalite.txt").strip.to_i
754
789
 
755
790
  # Actual space between objects
756
- actual_spaceship_distance = space_between_spaceships * base_multiplier
757
- actual_station_distance = space_between_station * base_multiplier
758
- actual_satalite_distance = space_between_satalite * base_multiplier
791
+ #actual_spaceship_distance = space_between_spaceships * base_multiplier
792
+ #actual_station_distance = space_between_station * base_multiplier
793
+ #actual_satalite_distance = space_between_satalite * base_multiplier
759
794
 
760
- puts "The minimum space between shuttles is #{actual_spaceship_distance} feet."; sleep(3)
761
- puts "The minimum space between stations is #{actual_station_distance} feet."; sleep(3)
762
- puts "The minimum space between satalites is #{actual_satalite_distance} feet."; sleep(3)
763
- end
795
+ #puts "The minimum space between shuttles is #{actual_spaceship_distance} feet."; sleep(3)
796
+ #puts "The minimum space between stations is #{actual_station_distance} feet."; sleep(3)
797
+ #puts "The minimum space between satalites is #{actual_satalite_distance} feet."; sleep(3)
798
+ #end
764
799
 
765
- end
766
- end
800
+ #end
801
+ #end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ImpUnit
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - LWFlouisa
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-10-14 00:00:00.000000000 Z
11
+ date: 2021-10-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler