samplab-url-tools 0.1.1

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 (5) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE +21 -0
  3. data/README.md +35 -0
  4. data/ruby/lib/samplab_url_tools.rb +19 -0
  5. metadata +44 -0
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: '09a7fdab138c0cc8cb3e170efc5a0bb68dd7e73d2237a9f25469f6f132379fd1'
4
+ data.tar.gz: 2c0d3e10250c9b86f91d74cfde4e5d22dabf719554ecc855b97b4d0de75f5617
5
+ SHA512:
6
+ metadata.gz: 26209725fd31035c1d6e7948f46dc9cf1ca18453a1047e1279bca1e5775a0a3f661dd18773b17c0b88d49309331d910923b2385d5a4fe4f2853381354140bd5f
7
+ data.tar.gz: 4bbf1def31d742add99b75152ac2073c84a859b81349af0a2a817473bbb111baccd1d165727f0b79600623afa46bf3d0042fe9268d15670d260447575ac7f041
data/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 bbwdadfg
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,35 @@
1
+ # samplab-url-tools
2
+
3
+ `samplab-url-tools` builds canonical HTTPS URLs for [SampLab Pro](https://samplab.pro/).
4
+
5
+ Offline URL builder for SampLab Pro, a browser audio and MIDI tool suite. Not an official SDK.
6
+
7
+ The helper only concatenates known page slugs. It does not call the site, upload files, or sign in.
8
+
9
+ ## JavaScript
10
+
11
+ ```js
12
+ import { pageUrl, pageUrl, pageUrl, pageUrl } from 'samplab-url-tools';
13
+
14
+ pageUrl('features'); // https://samplab.pro/features/
15
+ pageUrl('pricing'); // https://samplab.pro/pricing/
16
+ pageUrl('faq'); // https://samplab.pro/faq/
17
+ pageUrl('about'); // https://samplab.pro/about/
18
+ ```
19
+
20
+ ## Python
21
+
22
+ ```python
23
+ from samplab_url_tools import page_url, page_url, page_url, page_url
24
+
25
+ page_url('features') # https://samplab.pro/features/
26
+ page_url('pricing') # https://samplab.pro/pricing/
27
+ page_url('faq') # https://samplab.pro/faq/
28
+ page_url('about') # https://samplab.pro/about/
29
+ ```
30
+
31
+ The repository also contains equivalent Rust, PHP, and Go helpers, plus a small command that prints the same URLs.
32
+
33
+ Source: https://github.com/bbwdadfg/samplab-url-tools
34
+
35
+ License: MIT.
@@ -0,0 +1,19 @@
1
+ module SamplabUrlTools
2
+ BASE = "https://samplab.pro"
3
+ PAGES = { "features" => "/features/", "pricing" => "/pricing/", "faq" => "/faq/", "about" => "/about/" }
4
+ def self.home_url
5
+ BASE + "/"
6
+ end
7
+
8
+ def self.page_url(name)
9
+ path = PAGES[name]
10
+ raise ArgumentError, "unknown page: #{name}" if path.nil?
11
+ BASE + path
12
+ end
13
+
14
+ def self.tool_url(slug)
15
+ allowed = ["audio-to-midi", "bpm-key-finder", "chord-recognition", "frequency-band-splitter", "midi-to-audio", "lead-sheet-generator"]
16
+ raise ArgumentError, "unknown tool_url: #{slug}" unless allowed.include?(slug)
17
+ BASE + "/" + slug + "/"
18
+ end
19
+ end
metadata ADDED
@@ -0,0 +1,44 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: samplab-url-tools
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.1
5
+ platform: ruby
6
+ authors:
7
+ - bbwdadfg
8
+ bindir: bin
9
+ cert_chain: []
10
+ date: 1980-01-02 00:00:00.000000000 Z
11
+ dependencies: []
12
+ description: Offline URL builder for SampLab Pro, a browser audio and MIDI tool suite.
13
+ Not an official SDK.
14
+ executables: []
15
+ extensions: []
16
+ extra_rdoc_files: []
17
+ files:
18
+ - LICENSE
19
+ - README.md
20
+ - ruby/lib/samplab_url_tools.rb
21
+ homepage: https://samplab.pro/
22
+ licenses:
23
+ - MIT
24
+ metadata:
25
+ homepage_uri: https://samplab.pro/
26
+ source_code_uri: https://github.com/wangneo276-lgtm/samplab-url-tools
27
+ rdoc_options: []
28
+ require_paths:
29
+ - ruby/lib
30
+ required_ruby_version: !ruby/object:Gem::Requirement
31
+ requirements:
32
+ - - ">="
33
+ - !ruby/object:Gem::Version
34
+ version: '0'
35
+ required_rubygems_version: !ruby/object:Gem::Requirement
36
+ requirements:
37
+ - - ">="
38
+ - !ruby/object:Gem::Version
39
+ version: '0'
40
+ requirements: []
41
+ rubygems_version: 4.0.11
42
+ specification_version: 4
43
+ summary: Offline URL helpers for SampLab Pro
44
+ test_files: []