cafe_basics_duo 0.0.72 → 0.1.33

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/cafe_basics_duo.rb +175 -155
  3. metadata +3 -6
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e51bcfd1cd8cd92bf7683f554d7333e6d4b7118d2d90028d6200d5fde85b8a1c
4
- data.tar.gz: 6fbfc64564bdd5073db66d0e842a285ba68bedbffece76377662832b45559e87
3
+ metadata.gz: d41dca52ce32f729520ea19c0fee538e127cd50ddc24c45897883ee4dd09b331
4
+ data.tar.gz: 40cff0587a7ee6f9b14819b5b062014388acf818a401255bd6e72bb9dae93ea0
5
5
  SHA512:
6
- metadata.gz: 4361d64c4d19e18f955ac5b7b8d12de872ddbf7c1c525e47ab28765c794ca65b99b2c05de8d4180fc3eb8eb99a44c4698745f85da41a734b5da60140a1960c83
7
- data.tar.gz: baf710622d92af9fe1426700a1f23ae74bdf67fd003e627552eef20738b492b11f5440cade100fd0af7c0a521d4d018d69deb09fad5aedf6bc1570d003701577
6
+ metadata.gz: 620006031154254fc4a75709d8344dd6b60318e502bd374b045741a904f62de5e45411e2a7fc10a398922eb810b82821210f7c5b5feff9025d287afeeaa50fb4
7
+ data.tar.gz: 2bd6b2d74f70ecf298fbefc1fde2c1c7f4484e49c2c99a5600d88171c4fcc84bf1a857daa74b5e525d3e3c42c8e4141a53fca78b2ae0cb269278002376bfe795
@@ -2042,20 +2042,27 @@ class Wordpress
2042
2042
 
2043
2043
  def save_image
2044
2044
  if @data['이미지설정']['이미지'].length == 0
2045
-
2045
+ return
2046
+ end
2047
+
2048
+ if @data['이미지설정']['순서사용'].checked?
2049
+ image_path = @data['이미지설정']['이미지'][@image_counter][2]
2050
+ @image_counter += 1
2051
+ if @image_counter > @data['이미지설정']['이미지'].length - 1
2052
+ @image_counter = 0
2053
+ end
2046
2054
  else
2047
- if @data['이미지설정']['순서사용'].checked?
2048
- image_path = @data['이미지설정']['이미지'][@image_counter][2]
2049
- @image_counter += 1
2050
- if @image_counter > @data['이미지설정']['이미지'].length-1
2051
- @image_counter = 0
2052
- end
2053
- else
2054
- image_path = @data['이미지설정']['이미지'].sample[2]
2055
+ # 초기화가 안됐거나 다 썼으면 새롭게 섞는다
2056
+ @shuffled_images ||= []
2057
+ if @shuffled_images.empty?
2058
+ @shuffled_images = @data['이미지설정']['이미지'].shuffle
2055
2059
  end
2056
- img = Magick::Image.read(image_path).first
2057
- img.write('./image/memory.png')
2060
+
2061
+ image_path = @shuffled_images.shift[2]
2058
2062
  end
2063
+
2064
+ img = Magick::Image.read(image_path).first
2065
+ img.write('./image/memory.png')
2059
2066
  end
2060
2067
 
2061
2068
  def change_image_size(w)
@@ -2572,6 +2579,22 @@ class Wordpress
2572
2579
  @data['table'].pop
2573
2580
  #제목끝
2574
2581
  # content = " #{content} "
2582
+ if @data['포스트설정']['gpt키워드'].checked?
2583
+ gpt_keyword_prompt = @data['포스트설정']['gpt키워드_프롬프트'].text.to_s.force_encoding('utf-8')
2584
+ gpt_keyword_prompt_sample = gpt_keyword_prompt.strip.empty? ? "프롬프트: 관련된 글을 1500자에서 2500자 사이로 만들어줘" : gpt_keyword_prompt
2585
+ chat = Chat.new(@data['포스트설정']['api_key'].text.to_s.force_encoding('utf-8'), gpt_keyword_prompt)
2586
+ gpt_text = chat.message(keyword)
2587
+ #content = content.to_s + "\n(자동생성글)\n" + gpt_text.to_s
2588
+ content = content.to_s + "(자동생성글)" + gpt_text.to_s
2589
+ elsif @data['포스트설정']['내용을자동생성'].checked?
2590
+ content = auto_text
2591
+ elsif @data['포스트설정']['내용과자동생성'].checked?
2592
+ #content = content + "\n(자동생성글)\n" + auto_text
2593
+ content = content + "(자동생성글)" + auto_text
2594
+ end
2595
+ @data['table'][index][-1] = 45
2596
+ @data['table'] << []
2597
+ @data['table'].pop
2575
2598
 
2576
2599
  if @data['포스트설정']['특정단어굵기'].checked?
2577
2600
  content2 = ''
@@ -2611,7 +2634,7 @@ class Wordpress
2611
2634
  content = content2
2612
2635
  end
2613
2636
  end
2614
- @data['table'][index][-1] = 35
2637
+ @data['table'][index][-1] = 50
2615
2638
  @data['table'] << []
2616
2639
  @data['table'].pop
2617
2640
  if @data['포스트설정']['단어크기변경'].checked?
@@ -2632,19 +2655,7 @@ class Wordpress
2632
2655
  @data['table'][index][-1] = 50
2633
2656
  @data['table'] << []
2634
2657
  @data['table'].pop
2635
- if @data['포스트설정']['gpt키워드'].checked?
2636
- gpt_keyword_prompt = @data['포스트설정']['gpt키워드_프롬프트'].text.to_s.force_encoding('utf-8')
2637
- gpt_keyword_prompt_sample = gpt_keyword_prompt.strip.empty? ? "프롬프트: 관련된 글을 1500자에서 2500자 사이로 만들어줘" : gpt_keyword_prompt
2638
- chat = Chat.new(@data['포스트설정']['api_key'].text.to_s.force_encoding('utf-8'), gpt_keyword_prompt)
2639
- gpt_text = chat.message(keyword)
2640
- #content = content.to_s + "\n(자동생성글)\n" + gpt_text.to_s
2641
- content = content.to_s + "(자동생성글)" + gpt_text.to_s
2642
- elsif @data['포스트설정']['내용을자동생성'].checked?
2643
- content = auto_text
2644
- elsif @data['포스트설정']['내용과자동생성'].checked?
2645
- #content = content + "\n(자동생성글)\n" + auto_text
2646
- content = content + "(자동생성글)" + auto_text
2647
- end
2658
+
2648
2659
 
2649
2660
  if @data['포스트설정']['내용키워드삽입'].checked?
2650
2661
  puts '내용키워드삽입...'
@@ -2829,134 +2840,86 @@ class Wordpress
2829
2840
  puts '내용사진자동삽입...'
2830
2841
  sn = @data['포스트설정']['내용사진자동삽입시작숫자'].text.to_s.force_encoding('utf-8').to_i
2831
2842
  en = @data['포스트설정']['내용사진자동삽입끝숫자'].text.to_s.force_encoding('utf-8').to_i
2843
+
2832
2844
  begin
2833
2845
  cn = rand(sn..en)
2834
2846
  rescue
2835
2847
  cn = 0
2836
2848
  puts 'cn = rand(sn..en) error cn = 1'
2837
2849
  end
2838
-
2850
+
2839
2851
  if cn != 0
2840
- position = Array.new
2852
+ # content5 구성 및 위치 배열 생성
2841
2853
  if @data['포스트설정']['내용과자동생성'].checked?
2842
- if @data['포스트설정']['자동글 수식에 입력'].checked?
2843
- for n in 1..cn
2844
- position << rand(0..(content.split("(자동생성글)")[0].split("\n").length-1))
2845
- sleep(2)
2846
- end
2847
- else
2848
- for n in 1..cn
2849
- position << rand(0..(content.split("(자동생성글)")[0].split("\n").length-1))
2850
- sleep(2)
2851
- end
2852
- end
2853
- # position.pop
2854
- else
2855
- for n in 1..cn
2856
- position << rand(0..(content.split("\n").length-2))
2857
- sleep(2)
2858
- end
2859
- end
2860
-
2861
- if @data['포스트설정']['내용과자동생성'].checked? or @data['포스트설정']['gpt키워드'].checked?
2862
2854
  if @data['포스트설정']['자동글 수식에 입력'].checked?
2863
2855
  content5 = content.split("(자동생성글)")[0].to_s.split("\n")
2864
2856
  content55 = content.split("(자동생성글)")[1].to_s
2857
+ position = content5.length.times.to_a.sample(cn).sort.reverse
2865
2858
  else
2866
2859
  content5 = content.split("(자동생성글)")[0].to_s.split("\n")
2867
2860
  content55 = content.split("(자동생성글)")[1].to_s
2861
+ position = content5.length.times.to_a.sample(cn).sort.reverse
2868
2862
  end
2863
+ elsif @data['포스트설정']['gpt키워드'].checked?
2864
+ content5 = content.split("(자동생성글)")[1].to_s.split("\n")
2865
+ content_prefix = content.split("(자동생성글)")[0].to_s
2866
+ content55 = ''
2867
+ position = content5.length.times.to_a.sample(cn).sort.reverse
2869
2868
  else
2869
+ content5 = content.split("\n")
2870
2870
  content55 = ''
2871
- content5 = content.split("(자동생성글)")[0].to_s.split("\n")
2871
+ position = content5.length.times.to_a.sample(cn).sort.reverse
2872
2872
  end
2873
-
2874
- p content5
2875
- puts content55
2876
- p position
2877
-
2873
+
2874
+ # 중복 필터링 로직
2878
2875
  while true
2879
2876
  check11 = 0
2880
- for nn in 0..position.length-1
2881
- if content5[position[nn]].to_s.include?('style') or content5[position[nn]].to_s.include?('<') or content5[position[nn]].to_s.include?('>')
2877
+ position.each_with_index do |pos, idx|
2878
+ if content5[pos].to_s.include?('style') || content5[pos].to_s.include?('<') || content5[pos].to_s.include?('>')
2882
2879
  check11 = 1
2883
- position[nn] += 4
2880
+ position[idx] += 4
2884
2881
  end
2885
2882
  end
2886
- if check11 == 0
2887
- break
2888
- end
2883
+ break if check11 == 0
2889
2884
  end
2890
-
2891
- position = position.sort
2892
- ##여기서부터 이미지 순서대로 안되서 변경####-------------------------------------------------------------------------------
2893
- # if @data['포스트설정']['내용과자동생성'].checked? or @data['포스트설정']['gpt키워드'].checked?
2894
- # image_url22 = get_image_file().force_encoding('utf-8')
2895
- # end
2896
-
2897
- # position.each do |i|
2898
- # image_url = get_image_file().force_encoding('utf-8')
2899
- # puts image_url
2900
-
2901
- # puts '사진넣는위치 => '+i.to_s
2902
- # if @data['포스트설정']['내용사진링크'].checked?
2903
- # image_memory << ""+'<a href="'+@data['포스트설정']['내용사진링크값'].text.to_s.force_encoding('utf-8').force_encoding('utf-8')+'"><img src="'+image_url+'" alt="'+keyword.force_encoding('utf-8')+'"></a>'+""
2904
- # content5.insert(i, '**image**')
2905
- # else
2906
- # image_memory << ""+'<img src="'+image_url+'" alt="'+keyword+'" class="aligncenter size-full">'+""
2907
- # content5.insert(i, '**image**')
2908
- # end
2909
- # end
2910
-
2911
- # if @data['포스트설정']['내용과자동생성'].checked? or @data['포스트설정']['gpt키워드'].checked?
2912
- # content = content5.join("\n")+'(자동생성글)'+content55
2913
- # iconv = Iconv.new('UTF-8', 'ASCII-8BIT')
2914
- # content = iconv.iconv(content)
2915
- # content = content.encode('UTF-8', 'binary', invalid: :replace, replace: '')
2916
- # puts content
2917
- # image_url = image_url22
2918
-
2919
- # if @data['포스트설정']['자동글 수식에 입력'].checked?
2920
-
2921
- # else
2922
- # if @data['포스트설정']['내용사진링크'].checked?
2923
- # content = content.split('(자동생성글)')[0]+""+'<a href="'+@data['포스트설정']['내용사진링크값'].text.to_s.force_encoding('utf-8')+'"><img src="'+image_url+'" alt="'+keyword+'"></a>'+""+'(자동생성글)'+content.split('(자동생성글)')[1]
2924
- # else
2925
- # content = content.split('(자동생성글)')[0]+""+'<img src="'+image_url+'" alt="'+keyword+'" >'+""+'(자동생성글)'+content.split('(자동생성글)')[1]
2926
- # end
2927
- # end
2928
- ###여기까지 이미지 순서대로 안되서 변경##-------------------------------------------------------------------------------
2929
-
2930
- ##여기서부터 이미지 순서대로 수정코드 변경####-------------------------------------------------------------------------------
2931
- if @data['포스트설정']['내용과자동생성'].checked? or @data['포스트설정']['gpt키워드'].checked?
2885
+
2886
+ if @data['포스트설정']['내용과자동생성'].checked? || @data['포스트설정']['gpt키워드'].checked?
2887
+ sleep(2)
2888
+ puts '이미지 자동 세탁 중 · · · '
2889
+ end
2890
+
2891
+ p content5
2892
+ puts content55
2893
+ p position
2894
+
2932
2895
  sleep(2)
2933
- puts '이미지 자동 세탁 중 · · · '
2934
- end
2935
- sleep(2)
2936
- position.each do |i|
2937
- image_url22 = get_image_file().force_encoding('utf-8')
2938
- puts image_url22
2939
- puts '사진넣는위치 => '+i.to_s
2940
- if @data['포스트설정']['내용사진링크'].checked?
2941
- image_memory << ""+'<a href="'+@data['포스트설정']['내용사진링크값'].text.to_s.force_encoding('utf-8').force_encoding('utf-8')+'"><img src="'+image_url22+'" alt="'+keyword.force_encoding('utf-8')+'"></a>'+""
2942
- content5.insert(i, '**image**')
2943
- else
2944
- image_memory << ""+'<img src="'+image_url22+'" alt="'+keyword+'" class="aligncenter size-full">'+""
2945
- content5.insert(i, '**image**')
2896
+ position.each do |i|
2897
+ image_url22 = get_image_file().force_encoding('utf-8')
2898
+ if @data['포스트설정']['내용사진링크'].checked?
2899
+ image_tag = '<a href="' + @data['포스트설정']['내용사진링크값'].text.to_s.force_encoding('utf-8') +
2900
+ '"><img src="' + image_url22 + '" alt="' + keyword.force_encoding('utf-8') + '" class="aligncenter size-full"></a>'
2901
+ else
2902
+ image_tag = '<img src="' + image_url22 + '" alt="' + keyword + '" class="aligncenter size-full">'
2903
+ end
2904
+ content5.insert(i, image_tag)
2946
2905
  end
2947
- end
2948
- sleep(2)
2949
- puts '이미지 자동 세탁 완료 · · · '
2950
- if @data['포스트설정']['내용과자동생성'].checked? or @data['포스트설정']['gpt키워드'].checked?
2951
- content = content5.join("\n")+'(자동생성글)'+content55
2952
- puts content
2953
- ##여기서부터 이미지 순서대로 수정코드 변경####-------------------------------------------------------------------------------
2906
+
2907
+ sleep(2)
2908
+ puts '이미지 자동 세탁 완료 · · · '
2909
+
2910
+ if @data['포스트설정']['내용과자동생성'].checked?
2911
+ content = content5.join("\n") + '(자동생성글)' + content55
2912
+ elsif @data['포스트설정']['gpt키워드'].checked?
2913
+ content = content_prefix + "(자동생성글)" + content5.join("\n")
2954
2914
  else
2955
2915
  content = content5.join("\n")
2956
2916
  end
2957
2917
  end
2958
2918
  end
2919
+
2959
2920
 
2921
+
2922
+ ##여기서부터 이미지 순서대로 수정코드 변경####-------------------------------------------------------------------------------
2960
2923
  @data['table'][index][-1] = 70
2961
2924
  @data['table'] << []
2962
2925
  @data['table'].pop
@@ -2964,13 +2927,22 @@ class Wordpress
2964
2927
  content_memory = content.split('(자동생성글)')
2965
2928
  content = content_memory[0]
2966
2929
  content_end = content_memory[1].to_s
2930
+ if @data['포스트설정']['gpt키워드'].checked?
2931
+ if @data['포스트설정']['gpt상단'].checked?
2932
+ content = "(자동생성글)\n" + content_end + "\n" + content
2933
+ else
2934
+ content = content + "\n(자동생성글)\n" + content_end
2935
+ end
2936
+ else
2937
+ content = content + "\n(자동생성글)\n" + content_end
2938
+ end
2967
2939
 
2968
2940
  if @data['포스트설정']['특정단어키워드로변경'].checked?
2969
2941
  @data['포스트설정']['특정단어키워드로변경값'].text.to_s.force_encoding('utf-8').split(',').each do |i|
2970
2942
  content = content.split(i.force_encoding('utf-8')).join(keyword)
2971
2943
  end
2972
2944
  end
2973
-
2945
+
2974
2946
  @data['table'][index][-1] = 75
2975
2947
  @data['table'] << []
2976
2948
  @data['table'].pop
@@ -2987,12 +2959,7 @@ class Wordpress
2987
2959
  ttr = 0
2988
2960
  @data['포스트설정']['단어사진으로변경단어'].text.to_s.force_encoding('utf-8').split(',').each do |i|
2989
2961
  ttr = 1
2990
- # image_url = get_image_file().force_encoding('utf-8')
2991
- # if @data['포스트설정']['내용사진링크'].checked?
2992
- # content = content.split(i.force_encoding('utf-8')).join('<a href="'+@data['포스트설정']['내용사진링크값'].text.to_s.force_encoding('utf-8')+'"><img src="'+image_url+'" alt="'+keyword+'"></a>')
2993
- # else
2994
- # content = content.split(i.force_encoding('utf-8')).join('<img src="'+image_url+'" alt="'+keyword+'">')
2995
- # end
2962
+
2996
2963
  content = content.split(i.force_encoding('utf-8'))
2997
2964
  content.each_with_index do |ccm, index3|
2998
2965
  if index3 == content.length-1
@@ -3002,6 +2969,7 @@ class Wordpress
3002
2969
  if i.force_encoding('utf-8').to_s.include?('@')
3003
2970
  image_memory << ""+'<img src="'+image_url+'" alt="'+keyword+'">'+""
3004
2971
  content[index3] = content[index3] + '**image()**'
2972
+
3005
2973
  else
3006
2974
  image_memory << ""+ '<img src="'+image_url+'" alt="'+keyword+'">'+""
3007
2975
  content[index3] = content[index3] + '**image**'
@@ -3011,6 +2979,8 @@ class Wordpress
3011
2979
  content = content.join('')
3012
2980
  end
3013
2981
  end
2982
+
2983
+
3014
2984
 
3015
2985
  con_memory = Array.new
3016
2986
  index5 = 0
@@ -3048,6 +3018,8 @@ class Wordpress
3048
3018
  content = content.split(i.force_encoding('utf-8')).join("<sticker></sticker>")
3049
3019
  end
3050
3020
  end
3021
+
3022
+
3051
3023
 
3052
3024
  if @data['포스트설정']['영상으로변경'].checked?
3053
3025
  if @video.length == 0
@@ -3076,36 +3048,79 @@ class Wordpress
3076
3048
  # end
3077
3049
  #end
3078
3050
  if @data['포스트설정']['지도로변경'].checked?
3079
- # 지도 주소와 사용자 설정 단어들을 가져옵니다.
3080
3051
  map_address = @data['포스트설정']['지도주소'].text.to_s.force_encoding('utf-8')
3081
-
3082
- # 여러 단어로 설정된 '지도로변경단어'를 분리하여 배열로 저장
3083
3052
  change_words = @data['포스트설정']['지도로변경단어'].text.to_s.force_encoding('utf-8').split(',')
3084
3053
 
3085
- # content를 각 줄로 분할
3086
3054
  content_lines = content.split("\n")
3055
+ new_lines = []
3056
+
3057
+ content_lines.each do |line|
3058
+ # 이미 처리된 줄은 건너뜀
3059
+ if line.include?("<koreamap>")
3060
+ new_lines << line
3061
+ next
3062
+ end
3063
+
3064
+ processed = false
3087
3065
 
3088
- content_lines.each_with_index do |line, index|
3089
- # 각 단어에 대해 처리
3090
3066
  change_words.each do |change_word|
3091
- # 'change_word'가 포함된 줄에 대해서만 처리
3092
- if line.include?(change_word)
3093
- # 설정된 단어 뒤에 괄호가 있는지 확인
3094
- if line.include?("[") && line.include?("]")
3095
- # 괄호 안의 주소를 찾아서 그 주소는 그대로 두고, 지도로 변경된 주소로 교체
3096
- address_in_brackets = line.match(/\[(.*?)\]/)[1] # 괄호 안의 주소를 추출
3097
- content_lines[index] = "<koreamap>#{address_in_brackets}</koreamap>"
3098
- else
3099
- # 괄호가 없다면 @data['포스트설정']['지도주소']를 추가
3100
- content_lines[index] = "<koreamap>#{map_address}</koreamap>"
3067
+ # 1. [단어][주소] 패턴 처리: 분리 + 출력
3068
+ if line =~ /#{Regexp.escape(change_word)}\[(.*?)\]/
3069
+ match_data = line.match(/(.*)#{Regexp.escape(change_word)}\[(.*?)\](.*)/)
3070
+ if match_data
3071
+ before = match_data[1]
3072
+ address = match_data[2]
3073
+ after = match_data[3]
3074
+
3075
+ # 태그 추출
3076
+ open_tag = before[/<p[^>]*?>/i] || ""
3077
+ close_tag = after[/<\/p>/i] || ""
3078
+
3079
+ # 텍스트 정리
3080
+ before_text = before.sub(open_tag, '')
3081
+ after_text = after.sub(close_tag, '')
3082
+
3083
+ # 줄 분리
3084
+ new_lines << "#{open_tag}#{before_text}</p>" unless before_text.strip.empty?
3085
+ new_lines << "<koreamap>#{address}</koreamap>"
3086
+ new_lines << "#{open_tag}#{after_text}#{close_tag}" unless after_text.strip.empty?
3087
+
3088
+ processed = true
3089
+ break
3101
3090
  end
3102
3091
  end
3092
+
3093
+ # 2. 일반 단어 처리 (한 줄에만 등장하는 경우)
3094
+ if !processed && line.include?(change_word)
3095
+ parts = line.split(change_word, 2)
3096
+ prefix = parts[0]
3097
+ suffix = parts[1]
3098
+
3099
+ open_tag = prefix[/<p[^>]*?>/i] || ""
3100
+ close_tag = suffix[/<\/p>/i] || ""
3101
+
3102
+ prefix_text = prefix.sub(open_tag, '')
3103
+ suffix_text = suffix.sub(close_tag, '')
3104
+
3105
+ new_lines << "#{open_tag}#{prefix_text}</p>" unless prefix_text.strip.empty?
3106
+ new_lines << "<koreamap>#{map_address}</koreamap>"
3107
+ new_lines << "#{open_tag}#{suffix_text}#{close_tag}" unless suffix_text.strip.empty?
3108
+
3109
+ processed = true
3110
+ break
3111
+ end
3103
3112
  end
3113
+
3114
+ # 변경이 없었으면 원래 줄 추가
3115
+ new_lines << line unless processed
3104
3116
  end
3105
3117
 
3106
- # 다시 content로 합치기
3107
- content = content_lines.join("\n")
3118
+ content = new_lines.join("\n")
3108
3119
  end
3120
+
3121
+
3122
+
3123
+
3109
3124
 
3110
3125
  if @data['포스트설정']['인용구변경'].checked?
3111
3126
  if @data['포스트설정']['인용구문구설정'].checked?
@@ -3143,21 +3158,26 @@ class Wordpress
3143
3158
  @data['table'] << []
3144
3159
  @data['table'].pop
3145
3160
 
3161
+
3162
+ parts = content.split('(자동생성글)', 2)
3163
+ content_main = parts[0].strip
3164
+ content_end = parts[1].to_s.strip
3165
+
3146
3166
  soosick_1 = ''
3147
3167
  soosick_2 = ''
3148
3168
  if @data['포스트설정']['자동글 수식에 입력'].checked?
3149
- content = content
3150
- soosick_1 = content_end
3169
+ content = content_main
3170
+ soosick_1 = content_end
3151
3171
  else
3152
- if @data['포스트설정']['gpt키워드'].checked?
3153
- if @data['포스트설정']['gpt상단'].checked?
3154
- content = content_end+"\n"+content+"\n"
3155
- else
3156
- content = content+"\n"+content_end+"\n"
3157
- end
3172
+ if @data['포스트설정']['gpt키워드'].checked?
3173
+ if @data['포스트설정']['gpt상단'].checked?
3174
+ content = content_end + "\n" + content_main + "\n"
3158
3175
  else
3159
- content = content+"\n"+content_end+"\n"
3176
+ content = content_main + "\n" + content_end + "\n"
3160
3177
  end
3178
+ else
3179
+ content = content_main + "\n" + content_end + "\n"
3180
+ end
3161
3181
  end
3162
3182
 
3163
3183
  if @data['포스트설정']['막글삽입'].checked?
metadata CHANGED
@@ -1,14 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cafe_basics_duo
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.72
4
+ version: 0.1.33
5
5
  platform: ruby
6
6
  authors:
7
7
  - zon
8
- autorequire:
9
8
  bindir: bin
10
9
  cert_chain: []
11
- date: 2025-03-07 00:00:00.000000000 Z
10
+ date: 2025-04-24 00:00:00.000000000 Z
12
11
  dependencies: []
13
12
  description: File to Clipboard gem
14
13
  email: mymin26@naver.com
@@ -21,7 +20,6 @@ homepage: ''
21
20
  licenses:
22
21
  - zon
23
22
  metadata: {}
24
- post_install_message:
25
23
  rdoc_options: []
26
24
  require_paths:
27
25
  - lib
@@ -36,8 +34,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
36
34
  - !ruby/object:Gem::Version
37
35
  version: '0'
38
36
  requirements: []
39
- rubygems_version: 3.3.7
40
- signing_key:
37
+ rubygems_version: 3.6.7
41
38
  specification_version: 4
42
39
  summary: file to clipboard
43
40
  test_files: []