Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions .rubocop.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,9 @@
require: rubocop-performance
plugins:
- rubocop-performance

AllCops:
TargetRubyVersion: 3.1
Exclude:
- '**/bin/**/*'
- '**/db/**/*'
- '**/script/setup'
- '**/vendor/**/*'
NewCops: enable
SuggestExtensions: false

Lint/AssignmentInCondition:
Enabled: false
Expand All @@ -32,3 +29,6 @@ Style/TrailingCommaInArrayLiteral:

Style/TrailingCommaInHashLiteral:
EnforcedStyleForMultiline: consistent_comma

Layout/EndOfLine:
EnforcedStyle: native
4 changes: 4 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ GEM
ffi (1.17.2-arm-linux-gnu)
ffi (1.17.2-arm-linux-musl)
ffi (1.17.2-arm64-darwin)
ffi (1.17.2-x64-mingw-ucrt)
ffi (1.17.2-x86-linux-gnu)
ffi (1.17.2-x86-linux-musl)
ffi (1.17.2-x86_64-darwin)
Expand Down Expand Up @@ -276,6 +277,8 @@ GEM
racc (~> 1.4)
nokogiri (1.19.4-arm64-darwin)
racc (~> 1.4)
nokogiri (1.19.4-x64-mingw-ucrt)
racc (~> 1.4)
nokogiri (1.19.4-x86_64-darwin)
racc (~> 1.4)
nokogiri (1.19.4-x86_64-linux-gnu)
Expand Down Expand Up @@ -358,6 +361,7 @@ PLATFORMS
arm-linux-musl
arm64-darwin
ruby
x64-mingw-ucrt
x86-linux
x86-linux-gnu
x86-linux-musl
Expand Down
17 changes: 17 additions & 0 deletions collections/vlc-media-player/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
items:
- videolan/vlc
- mpv-player/mpv
- jellyfin/jellyfin
- HandBrake/HandBrake
- obsproject/obs-studio
- xbmc/xbmc
- iina/iina
- mpc-hc/mpc-hc
- celerity/bino
display_name: VLC Media Player
created_by: VideoLAN
---
# Video Players and Tools

Stream, play, and transcode digital media with these powerful video applications.
6 changes: 3 additions & 3 deletions test/collections_test.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
require_relative "./collections_test_helper"
require_relative "collections_test_helper"

describe "collections" do
collections.each do |collection|
Expand Down Expand Up @@ -34,7 +34,7 @@

it "has valid number of items" do
items = items_for_collection(collection)
assert (1...MAX_COLLECTION_ITEMS_LENGTH + 1).cover?(items.length),
assert (1...(MAX_COLLECTION_ITEMS_LENGTH + 1)).cover?(items.length),
"must have no more than #{MAX_COLLECTION_ITEMS_LENGTH} items " \
"(currently #{items.length})"
end
Expand Down Expand Up @@ -82,7 +82,7 @@
assert metadata.key?(key), "expected to have '#{key}' defined for collection"
metadata_value = metadata[key].is_a?(Array) ? metadata[key] : [metadata[key]]
assert !metadata_value.empty? &&
metadata_value.all? { |value| value&.strip&.size&.positive? },
metadata_value.all? { |value| !value.to_s.strip.empty? },
"expected to have a value for '#{key}'"
end
end
Expand Down
8 changes: 4 additions & 4 deletions test/collections_test_helper.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
require_relative "./test_helper"
require_relative "test_helper"
require "fileutils"

VALID_COLLECTION_METADATA_KEYS = %w[collection created_by display_name image items].freeze
Expand All @@ -16,7 +16,7 @@

def invalid_collection_message(collection)
"'#{collection}' must be between 1-#{MAX_COLLECTION_SLUG_LENGTH} characters, " \
"start with a letter or number, and may include hyphens"
"start with a letter or number, and may include hyphens"
end

def valid_collection?(raw_collection)
Expand All @@ -34,7 +34,7 @@ def collections_dir
end

def collection_dirs
collection_directories = dirs_to_test.split(" ").map do |file|
collection_directories = dirs_to_test.split.map do |file|
directory = file.split("/")[1]
[collections_dir, directory].join("/")
end
Expand Down Expand Up @@ -134,7 +134,7 @@ def prefetch_all_collection_items!
def collect_all_collection_items
all_items = collections.flat_map { |c| items_for_collection(c) || [] }

repos = all_items.select { |item| item.match?(USERNAME_AND_REPO_REGEX) }.uniq
repos = all_items.grep(USERNAME_AND_REPO_REGEX).uniq
users = all_items
.select { |item| item.match?(USERNAME_REGEX) && !item.match?(USERNAME_AND_REPO_REGEX) }
.uniq
Expand Down
4 changes: 2 additions & 2 deletions test/topics_test.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
require_relative "./topics_test_helper"
require_relative "topics_test_helper"

describe "topics" do
# Used by the Topics Page Style Guide test
Expand Down Expand Up @@ -279,7 +279,7 @@

REQUIRED_TOPIC_METADATA_KEYS.each do |key|
assert metadata.key?(key), "expected to have '#{key}' defined for topic"
assert metadata[key]&.strip&.size&.positive?,
assert !metadata[key].to_s.strip.empty?,
"expected to have a value for '#{key}'"
end
end
Expand Down
4 changes: 2 additions & 2 deletions test/topics_test_helper.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
require_relative "./test_helper"
require_relative "test_helper"

VALID_TOPIC_METADATA_KEYS = %w[aliases created_by display_name github_url logo related
released short_description topic url wikipedia_url].freeze
Expand Down Expand Up @@ -42,7 +42,7 @@ def topics_dir
end

def topic_dirs
topic_directories = dirs_to_test.split(" ").map do |file|
topic_directories = dirs_to_test.split.map do |file|
directory = file.split("/")[1]
[topics_dir, directory].join("/")
end
Expand Down
9 changes: 9 additions & 0 deletions topics/vlc-media-player/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
aliases: vlc-player, videolan, vlc
display_name: VLC
short_description: Vlc is a free and open-source cross-platform multimedia player.
topic: vlc-media-player
logo: vlc-media-player.png
wikipedia_url: https://en.wikipedia.org/wiki/VLC_media_player
---
VLC Media Player is a portable, free and open-source, cross-platform media player software and streaming media server.
Binary file added topics/vlc-media-player/vlc-media-player.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading