duo_blog_cafe_comment 0.0.61 → 0.0.65
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.
- checksums.yaml +4 -4
- data/lib/duo_blog_cafe_comment.rb +93 -57
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 12b619dc6f0c2ce1233fd9f255f80854c9692bbd5a321cd54849dfbb4b4c9d6f
|
4
|
+
data.tar.gz: 94097c6c468da0fab709f98b256f15bfd5f8c5c42fe91d8a881fa383ee60eb8e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c9087fa0c7a96c4846b8aa5c66fec3b66e166dec6e5c17b9602ec33d9a6db735d26aa60396c4d419f22796ac4877753383a582c83dc53a7eaccb4096c56eb711
|
7
|
+
data.tar.gz: e2d4d83baecb36f84cfd8f910d42db36e39c8b8fdd1aec7b8cd1430b1d9d247f893d3177154d035572f0f2586f70879bf3e444de7a4700b64c489d3ed30a338d
|
@@ -499,21 +499,22 @@ class Naver
|
|
499
499
|
@driver.action.send_keys(:page_down).perform #스크롤 내리기
|
500
500
|
sleep(1)
|
501
501
|
|
502
|
-
|
503
|
-
|
504
|
-
|
505
|
-
|
506
|
-
|
507
|
-
if @data.dig('내용설정', '랜덤사용')&.respond_to?(:checked?) && @data['내용설정']['랜덤사용'].checked?
|
508
|
-
content = @data['내용설정']['내용'].sample[2] # 랜덤 사용 시
|
502
|
+
if @data['포스트설정']['순서사용2'].checked?
|
503
|
+
@content_soon ||= 0 # 초기 한 번만 0으로 세팅
|
504
|
+
|
505
|
+
if @data['내용설정']['내용'].nil? || @data['내용설정']['내용'].empty?
|
506
|
+
content = ''
|
509
507
|
else
|
510
|
-
|
511
|
-
|
512
|
-
|
513
|
-
|
508
|
+
if @data.dig('내용설정', '랜덤사용')&.respond_to?(:checked?) && @data['내용설정']['랜덤사용'].checked?
|
509
|
+
content = @data['내용설정']['내용'].sample[2]
|
510
|
+
else
|
511
|
+
content = @data['내용설정']['내용'][@content_soon][2]
|
512
|
+
@content_soon += 1
|
513
|
+
@content_soon = 0 if @content_soon >= @data['내용설정']['내용'].length
|
514
514
|
end
|
515
515
|
end
|
516
|
-
|
516
|
+
else
|
517
|
+
end
|
517
518
|
|
518
519
|
# 디엠 자동 변경이 체크된 경우 content를 변환
|
519
520
|
if @data['포스트설정']['내용자동변경'].checked?
|
@@ -766,21 +767,22 @@ class Naver
|
|
766
767
|
@driver.action.send_keys(:page_down).perform #스크롤 내리기
|
767
768
|
sleep(1)
|
768
769
|
|
769
|
-
|
770
|
-
|
771
|
-
|
772
|
-
|
773
|
-
|
774
|
-
if @data.dig('내용설정', '랜덤사용')&.respond_to?(:checked?) && @data['내용설정']['랜덤사용'].checked?
|
775
|
-
content = @data['내용설정']['내용'].sample[2] # 랜덤 사용 시
|
770
|
+
if @data['포스트설정']['순서사용2'].checked?
|
771
|
+
@content_soon ||= 0 # 초기 한 번만 0으로 세팅
|
772
|
+
|
773
|
+
if @data['내용설정']['내용'].nil? || @data['내용설정']['내용'].empty?
|
774
|
+
content = ''
|
776
775
|
else
|
777
|
-
|
778
|
-
|
779
|
-
|
780
|
-
|
776
|
+
if @data.dig('내용설정', '랜덤사용')&.respond_to?(:checked?) && @data['내용설정']['랜덤사용'].checked?
|
777
|
+
content = @data['내용설정']['내용'].sample[2]
|
778
|
+
else
|
779
|
+
content = @data['내용설정']['내용'][@content_soon][2]
|
780
|
+
@content_soon += 1
|
781
|
+
@content_soon = 0 if @content_soon >= @data['내용설정']['내용'].length
|
781
782
|
end
|
782
783
|
end
|
783
|
-
|
784
|
+
else
|
785
|
+
end
|
784
786
|
|
785
787
|
# 디엠 자동 변경이 체크된 경우 content를 변환
|
786
788
|
if @data['포스트설정']['내용자동변경'].checked?
|
@@ -1115,20 +1117,21 @@ class Naver
|
|
1115
1117
|
@driver.action.send_keys(:page_down).perform #스크롤 내리기
|
1116
1118
|
sleep(1)
|
1117
1119
|
|
1118
|
-
|
1119
|
-
|
1120
|
-
|
1121
|
-
|
1122
|
-
|
1123
|
-
if @data.dig('내용설정', '랜덤사용')&.respond_to?(:checked?) && @data['내용설정']['랜덤사용'].checked?
|
1124
|
-
content = @data['내용설정']['내용'].sample[2] # 랜덤 사용 시
|
1120
|
+
if @data['포스트설정']['순서사용2'].checked?
|
1121
|
+
@content_soon ||= 0 # 초기 한 번만 0으로 세팅
|
1122
|
+
|
1123
|
+
if @data['내용설정']['내용'].nil? || @data['내용설정']['내용'].empty?
|
1124
|
+
content = ''
|
1125
1125
|
else
|
1126
|
-
|
1127
|
-
|
1128
|
-
|
1129
|
-
|
1126
|
+
if @data.dig('내용설정', '랜덤사용')&.respond_to?(:checked?) && @data['내용설정']['랜덤사용'].checked?
|
1127
|
+
content = @data['내용설정']['내용'].sample[2]
|
1128
|
+
else
|
1129
|
+
content = @data['내용설정']['내용'][@content_soon][2]
|
1130
|
+
@content_soon += 1
|
1131
|
+
@content_soon = 0 if @content_soon >= @data['내용설정']['내용'].length
|
1130
1132
|
end
|
1131
1133
|
end
|
1134
|
+
else
|
1132
1135
|
end
|
1133
1136
|
|
1134
1137
|
# 디엠 자동 변경이 체크된 경우 content를 변환
|
@@ -2137,21 +2140,22 @@ class Naver
|
|
2137
2140
|
else
|
2138
2141
|
end
|
2139
2142
|
|
2140
|
-
|
2141
|
-
|
2142
|
-
|
2143
|
-
|
2144
|
-
|
2145
|
-
if @data.dig('내용설정', '랜덤사용')&.respond_to?(:checked?) && @data['내용설정']['랜덤사용'].checked?
|
2146
|
-
content = @data['내용설정']['내용'].sample[2] # 랜덤 사용 시
|
2143
|
+
if @data['포스트설정']['순서사용2'].checked?
|
2144
|
+
@content_soon ||= 0 # 초기 한 번만 0으로 세팅
|
2145
|
+
|
2146
|
+
if @data['내용설정']['내용'].nil? || @data['내용설정']['내용'].empty?
|
2147
|
+
content = ''
|
2147
2148
|
else
|
2148
|
-
|
2149
|
-
|
2150
|
-
|
2151
|
-
|
2149
|
+
if @data.dig('내용설정', '랜덤사용')&.respond_to?(:checked?) && @data['내용설정']['랜덤사용'].checked?
|
2150
|
+
content = @data['내용설정']['내용'].sample[2]
|
2151
|
+
else
|
2152
|
+
content = @data['내용설정']['내용'][@content_soon][2]
|
2153
|
+
@content_soon += 1
|
2154
|
+
@content_soon = 0 if @content_soon >= @data['내용설정']['내용'].length
|
2152
2155
|
end
|
2153
2156
|
end
|
2154
|
-
|
2157
|
+
else
|
2158
|
+
end
|
2155
2159
|
|
2156
2160
|
# 디엠 자동 변경이 체크된 경우 content를 변환
|
2157
2161
|
if @data['포스트설정']['내용자동변경'].checked?
|
@@ -2170,14 +2174,25 @@ class Naver
|
|
2170
2174
|
begin #댓글 작업 >> 시작
|
2171
2175
|
# 댓글 쓰기 버튼 클릭
|
2172
2176
|
begin
|
2173
|
-
|
2174
|
-
|
2175
|
-
|
2176
|
-
|
2177
|
-
|
2178
|
-
|
2179
|
-
|
2180
|
-
|
2177
|
+
wait = Selenium::WebDriver::Wait.new(:timeout => 3)
|
2178
|
+
wait.until { @driver.find_element(:xpath, '//*[@class="area_comment pcol2"]') }
|
2179
|
+
element = @driver.find_element(:xpath, '//*[@class="area_comment pcol2"]')
|
2180
|
+
@driver.execute_script("arguments[0].scrollIntoView({block: 'center', inline: 'center'})", element) # 크롤 이동
|
2181
|
+
sleep(1)
|
2182
|
+
@driver.find_element(:xpath, '//*[@class="area_comment pcol2"]').click
|
2183
|
+
sleep(1)
|
2184
|
+
rescue
|
2185
|
+
begin
|
2186
|
+
wait = Selenium::WebDriver::Wait.new(:timeout => 3)
|
2187
|
+
wait.until { @driver.find_element(xpath: "//span[@class='btn_arr']//span[@class='blind']") }
|
2188
|
+
element = @driver.find_element(xpath: "//span[@class='btn_arr']//span[@class='blind']")
|
2189
|
+
@driver.execute_script("arguments[0].scrollIntoView({block: 'center', inline: 'center'})", element) # 크롤 이동
|
2190
|
+
sleep(1)
|
2191
|
+
@driver.find_element(xpath: "//span[@class='btn_arr']//span[@class='blind']").click
|
2192
|
+
sleep(1)
|
2193
|
+
rescue => e
|
2194
|
+
puts "댓글 작성 필드가 존재 하지않습니다."
|
2195
|
+
end
|
2181
2196
|
end
|
2182
2197
|
|
2183
2198
|
if option['댓글패스'] == 'true'
|
@@ -2864,7 +2879,17 @@ end
|
|
2864
2879
|
@data['table'] << []
|
2865
2880
|
@data['table'].pop
|
2866
2881
|
|
2867
|
-
|
2882
|
+
|
2883
|
+
if @data['포스트설정']['순서사용2'].checked?
|
2884
|
+
option['순서사용2'] = 'true'
|
2885
|
+
else
|
2886
|
+
option['순서사용2'] = 'false'
|
2887
|
+
end
|
2888
|
+
@data['table'][index][-1] = 35
|
2889
|
+
@data['table'] << []
|
2890
|
+
@data['table'].pop
|
2891
|
+
|
2892
|
+
|
2868
2893
|
|
2869
2894
|
#네이버로그인
|
2870
2895
|
login_check = naver.login(user_id, user_pw, option['proxy'])
|
@@ -4280,11 +4305,21 @@ end
|
|
4280
4305
|
|
4281
4306
|
horizontal_box{
|
4282
4307
|
stretchy false
|
4283
|
-
@data['내용설정']['순서사용'] = checkbox('순서사용'){
|
4308
|
+
@data['내용설정']['순서사용'] = checkbox('계정마다 순서사용'){
|
4284
4309
|
stretchy false
|
4285
4310
|
on_toggled{ |c|
|
4286
4311
|
if c.checked?
|
4287
4312
|
@data['내용설정']['랜덤사용'].checked = false
|
4313
|
+
@data['포스트설정']['순서사용2'].checked = false
|
4314
|
+
end
|
4315
|
+
}
|
4316
|
+
}
|
4317
|
+
@data['포스트설정']['순서사용2'] = checkbox('게시글마다 순서사용'){
|
4318
|
+
stretchy false
|
4319
|
+
on_toggled{ |c|
|
4320
|
+
if c.checked?
|
4321
|
+
@data['내용설정']['랜덤사용'].checked = false
|
4322
|
+
@data['내용설정']['순서사용'].checked = false
|
4288
4323
|
end
|
4289
4324
|
}
|
4290
4325
|
}
|
@@ -4293,6 +4328,7 @@ end
|
|
4293
4328
|
on_toggled{ |c|
|
4294
4329
|
if c.checked?
|
4295
4330
|
@data['내용설정']['순서사용'].checked = false
|
4331
|
+
@data['포스트설정']['순서사용2'].checked = false
|
4296
4332
|
end
|
4297
4333
|
}
|
4298
4334
|
}
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: duo_blog_cafe_comment
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.65
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- zon
|
8
8
|
bindir: bin
|
9
9
|
cert_chain: []
|
10
|
-
date: 2025-06-
|
10
|
+
date: 2025-06-27 00:00:00.000000000 Z
|
11
11
|
dependencies: []
|
12
12
|
description: File to Clipboard gem
|
13
13
|
email: mymin26@naver.com
|