mirror of
https://github.com/KevinMidboe/linguist.git
synced 2025-10-29 17:50:22 +00:00
Compare commits
56 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
e78e9e4747 | ||
|
|
81f9079f43 | ||
|
|
16eaa533b6 | ||
|
|
2e521a6c74 | ||
|
|
56a65d0975 | ||
|
|
e4c6c1d245 | ||
|
|
a9f366aed2 | ||
|
|
96bd08e391 | ||
|
|
02fe28eb25 | ||
|
|
e77530b390 | ||
|
|
d0370a3b4c | ||
|
|
ebce4890b2 | ||
|
|
1bc87aadb3 | ||
|
|
53a532dc76 | ||
|
|
0669a83e40 | ||
|
|
c4ab3b276f | ||
|
|
920f825496 | ||
|
|
f28573420e | ||
|
|
c471990aa3 | ||
|
|
baf56666d4 | ||
|
|
cbbc05f7b8 | ||
|
|
051906727b | ||
|
|
cfd5cbaba0 | ||
|
|
caaad886c3 | ||
|
|
2305f9051c | ||
|
|
392ab2960f | ||
|
|
1e134b5754 | ||
|
|
d356ea28af | ||
|
|
a015138dcd | ||
|
|
ff99d1bac8 | ||
|
|
f4af4727a1 | ||
|
|
2c3069db77 | ||
|
|
8845cd9c58 | ||
|
|
090f765c7e | ||
|
|
b58c0e8f3e | ||
|
|
b4ff170603 | ||
|
|
3bc540a283 | ||
|
|
25b761b506 | ||
|
|
1e502808c9 | ||
|
|
27e0c8f78a | ||
|
|
897218678e | ||
|
|
4eb33fe3be | ||
|
|
0614055efd | ||
|
|
e70f3f595a | ||
|
|
28af996bf9 | ||
|
|
8bd8f0960c | ||
|
|
255db77f1f | ||
|
|
8b0b14c9a6 | ||
|
|
95e83311b6 | ||
|
|
6c07476c45 | ||
|
|
1968f8193c | ||
|
|
5155ad89e8 | ||
|
|
c2505e8b7b | ||
|
|
b38f4b786b | ||
|
|
1a04c79738 | ||
|
|
a464c234b8 |
37
.gitmodules
vendored
37
.gitmodules
vendored
@@ -364,9 +364,6 @@
|
||||
[submodule "vendor/grammars/r.tmbundle"]
|
||||
path = vendor/grammars/r.tmbundle
|
||||
url = https://github.com/textmate/r.tmbundle
|
||||
[submodule "vendor/grammars/restructuredtext.tmbundle"]
|
||||
path = vendor/grammars/restructuredtext.tmbundle
|
||||
url = https://github.com/textmate/restructuredtext.tmbundle
|
||||
[submodule "vendor/grammars/ruby-haml.tmbundle"]
|
||||
path = vendor/grammars/ruby-haml.tmbundle
|
||||
url = https://github.com/textmate/ruby-haml.tmbundle
|
||||
@@ -446,9 +443,6 @@
|
||||
[submodule "vendor/grammars/Scalate.tmbundle"]
|
||||
path = vendor/grammars/Scalate.tmbundle
|
||||
url = https://github.com/scalate/Scalate.tmbundle
|
||||
[submodule "vendor/grammars/Elm.tmLanguage"]
|
||||
path = vendor/grammars/Elm.tmLanguage
|
||||
url = https://github.com/deadfoxygrandpa/Elm.tmLanguage
|
||||
[submodule "vendor/grammars/sublime-bsv"]
|
||||
path = vendor/grammars/sublime-bsv
|
||||
url = https://github.com/thotypous/sublime-bsv
|
||||
@@ -681,8 +675,8 @@
|
||||
path = vendor/grammars/pig-latin
|
||||
url = https://github.com/goblindegook/sublime-text-pig-latin
|
||||
[submodule "vendor/grammars/sourcepawn"]
|
||||
path = vendor/grammars/sourcepawn
|
||||
url = https://github.com/austinwagner/sublime-sourcepawn
|
||||
path = vendor/grammars/sourcepawn
|
||||
url = https://github.com/austinwagner/sublime-sourcepawn
|
||||
[submodule "vendor/grammars/gdscript"]
|
||||
path = vendor/grammars/gdscript
|
||||
url = https://github.com/beefsack/GDScript-sublime
|
||||
@@ -725,3 +719,30 @@
|
||||
[submodule "vendor/grammars/sublime-clips"]
|
||||
path = vendor/grammars/sublime-clips
|
||||
url = https://github.com/psicomante/CLIPS-sublime
|
||||
[submodule "vendor/grammars/creole"]
|
||||
path = vendor/grammars/creole
|
||||
url = https://github.com/Siddley/Creole
|
||||
[submodule "vendor/grammars/language-csound"]
|
||||
path = vendor/grammars/language-csound
|
||||
url = https://github.com/nwhetsell/language-csound
|
||||
[submodule "vendor/grammars/language-wavefront"]
|
||||
path = vendor/grammars/language-wavefront
|
||||
url = https://github.com/Alhadis/language-wavefront
|
||||
[submodule "vendor/grammars/nu.tmbundle"]
|
||||
path = vendor/grammars/nu.tmbundle
|
||||
url = https://github.com/jsallis/nu.tmbundle
|
||||
[submodule "vendor/grammars/Elm"]
|
||||
path = vendor/grammars/Elm
|
||||
url = https://github.com/elm-community/Elm.tmLanguage
|
||||
[submodule "vendor/grammars/language-restructuredtext"]
|
||||
path = vendor/grammars/language-restructuredtext
|
||||
url = https://github.com/Lukasa/language-restructuredtext
|
||||
[submodule "vendor/grammars/atom-language-clean"]
|
||||
path = vendor/grammars/atom-language-clean
|
||||
url = https://github.com/timjs/atom-language-clean.git
|
||||
[submodule "vendor/grammars/language-turing"]
|
||||
path = vendor/grammars/language-turing
|
||||
url = https://github.com/Alhadis/language-turing
|
||||
[submodule "vendor/grammars/atom-language-srt"]
|
||||
path = vendor/grammars/atom-language-srt
|
||||
url = https://github.com/314eter/atom-language-srt
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
# Contributing
|
||||
|
||||
[code-of-conduct]: http://todogroup.org/opencodeofconduct/#Linguist/opensource@github.com
|
||||
|
||||
Hi there! We're thrilled that you'd like to contribute to this project. Your help is essential for keeping it great. This project adheres to the [Open Code of Conduct][code-of-conduct]. By participating, you are expected to uphold this code.
|
||||
Hi there! We're thrilled that you'd like to contribute to this project. Your help is essential for keeping it great. This project adheres to the [Contributor Covenant Code of Conduct](http://contributor-covenant.org/). By participating, you are expected to uphold this code.
|
||||
|
||||
The majority of contributions won't need to touch any Ruby code at all.
|
||||
|
||||
@@ -79,8 +77,20 @@ Sometimes getting the tests running can be too much work, especially if you don'
|
||||
|
||||
Here's our current build status: [](https://travis-ci.org/github/linguist)
|
||||
|
||||
## Maintainers
|
||||
|
||||
## Releasing
|
||||
Linguist is maintained with :heart: by:
|
||||
|
||||
- @arfon (GitHub Staff)
|
||||
- @larsbrinkhoff
|
||||
- @pchaigno
|
||||
|
||||
As Linguist is a production dependency for GitHub we have a couple of workflow restrictions:
|
||||
|
||||
- Anyone with commit rights can merge Pull Requests provided that there is a :+1: from a GitHub member of staff
|
||||
- Releases are performed by GitHub staff so we can ensure GitHub.com always stays up to date with the latest release of Linguist and there are no regressions in production.
|
||||
|
||||
### Releasing
|
||||
|
||||
If you are the current maintainer of this gem:
|
||||
|
||||
|
||||
12
README.md
12
README.md
@@ -43,7 +43,7 @@ special-vendored-path/* linguist-vendored
|
||||
jquery.js linguist-vendored=false
|
||||
```
|
||||
|
||||
Similar to vendored files, Linguist excludes documentation files from your project's language stats. (Unlike vendored files, documentation files are displayed in diffs on github.com.) [lib/linguist/documentation.yml](lib/linguist/documentation.yml) lists common documentation paths and excludes them from the language statistics for your repository.
|
||||
Just like vendored files, Linguist excludes documentation files from your project's language stats. [lib/linguist/documentation.yml](lib/linguist/documentation.yml) lists common documentation paths and excludes them from the language statistics for your repository.
|
||||
|
||||
Use the `linguist-documentation` attribute to mark or unmark paths as documentation.
|
||||
|
||||
@@ -53,6 +53,16 @@ project-docs/* linguist-documentation
|
||||
docs/formatter.rb linguist-documentation=false
|
||||
```
|
||||
|
||||
#### Generated file detection
|
||||
|
||||
Not all plain text files are true source files. Generated files like minified js and compiled CoffeeScript can be detected and excluded from language stats. As an added bonus, unlike vendored and documentation files, these files are suppressed in diffs.
|
||||
|
||||
```ruby
|
||||
Linguist::FileBlob.new("underscore.min.js").generated? # => true
|
||||
```
|
||||
|
||||
See [Linguist::Generated#generated?](https://github.com/github/linguist/blob/master/lib/linguist/generated.rb).
|
||||
|
||||
### Using Emacs or Vim modelines
|
||||
|
||||
Alternatively, you can use Vim or Emacs style modelines to set the language for a single file. Modelines can be placed anywhere within a file and are respected when determining how to syntax-highlight a file on GitHub.com
|
||||
|
||||
28
grammars.yml
28
grammars.yml
@@ -18,8 +18,6 @@ http://svn.textmate.org/trunk/Review/Bundles/XQuery.tmbundle:
|
||||
https://bitbucket.org/Clams/sublimesystemverilog/get/default.tar.gz:
|
||||
- source.systemverilog
|
||||
- source.ucfconstraints
|
||||
https://fan.googlecode.com/hg-history/Build%201.0.55/adm/tools/textmate/Fan.tmbundle/Syntaxes/Fan.tmLanguage:
|
||||
- source.fan
|
||||
vendor/grammars/Agda.tmbundle:
|
||||
- source.agda
|
||||
vendor/grammars/Alloy.tmbundle:
|
||||
@@ -36,7 +34,7 @@ vendor/grammars/ColdFusion:
|
||||
- text.html.cfm
|
||||
vendor/grammars/Docker.tmbundle:
|
||||
- source.dockerfile
|
||||
vendor/grammars/Elm.tmLanguage:
|
||||
vendor/grammars/Elm/:
|
||||
- source.elm
|
||||
vendor/grammars/FreeMarker.tmbundle:
|
||||
- text.html.ftl
|
||||
@@ -178,8 +176,12 @@ vendor/grammars/atom-fsharp/:
|
||||
- source.fsharp.fsi
|
||||
- source.fsharp.fsl
|
||||
- source.fsharp.fsx
|
||||
vendor/grammars/atom-language-clean:
|
||||
- source.clean
|
||||
vendor/grammars/atom-language-purescript/:
|
||||
- source.purescript
|
||||
vendor/grammars/atom-language-srt:
|
||||
- text.srt
|
||||
vendor/grammars/atom-language-stan/:
|
||||
- source.stan
|
||||
vendor/grammars/atom-salt:
|
||||
@@ -219,6 +221,8 @@ vendor/grammars/cool-tmbundle:
|
||||
vendor/grammars/cpp-qt.tmbundle:
|
||||
- source.c++.qt
|
||||
- source.qmake
|
||||
vendor/grammars/creole/:
|
||||
- text.html.creole
|
||||
vendor/grammars/css.tmbundle:
|
||||
- source.css
|
||||
vendor/grammars/cucumber-tmbundle:
|
||||
@@ -337,11 +341,16 @@ vendor/grammars/language-coffee-script:
|
||||
- source.litcoffee
|
||||
vendor/grammars/language-crystal:
|
||||
- source.crystal
|
||||
- text.html.ecr
|
||||
vendor/grammars/language-csharp:
|
||||
- source.cake
|
||||
- source.cs
|
||||
- source.csx
|
||||
- source.nant-build
|
||||
vendor/grammars/language-csound:
|
||||
- source.csound
|
||||
- source.csound-document
|
||||
- source.csound-score
|
||||
vendor/grammars/language-gfm:
|
||||
- source.gfm
|
||||
vendor/grammars/language-graphql:
|
||||
@@ -370,6 +379,8 @@ vendor/grammars/language-python:
|
||||
- text.python.traceback
|
||||
vendor/grammars/language-renpy:
|
||||
- source.renpy
|
||||
vendor/grammars/language-restructuredtext:
|
||||
- text.restructuredtext
|
||||
vendor/grammars/language-shellscript:
|
||||
- source.shell
|
||||
- text.shell-session
|
||||
@@ -377,6 +388,11 @@ vendor/grammars/language-supercollider:
|
||||
- source.supercollider
|
||||
vendor/grammars/language-toc-wow:
|
||||
- source.toc
|
||||
vendor/grammars/language-turing:
|
||||
- source.turing
|
||||
vendor/grammars/language-wavefront:
|
||||
- source.wavefront.mtl
|
||||
- source.wavefront.obj
|
||||
vendor/grammars/language-xbase:
|
||||
- source.harbour
|
||||
vendor/grammars/language-yaml:
|
||||
@@ -431,6 +447,8 @@ vendor/grammars/ninja.tmbundle:
|
||||
- source.ninja
|
||||
vendor/grammars/nix:
|
||||
- source.nix
|
||||
vendor/grammars/nu.tmbundle:
|
||||
- source.nu
|
||||
vendor/grammars/objective-c.tmbundle:
|
||||
- source.objc
|
||||
- source.objc++
|
||||
@@ -480,8 +498,6 @@ vendor/grammars/python-django.tmbundle:
|
||||
vendor/grammars/r.tmbundle:
|
||||
- source.r
|
||||
- text.tex.latex.rd
|
||||
vendor/grammars/restructuredtext.tmbundle:
|
||||
- text.restructuredtext
|
||||
vendor/grammars/ruby-haml.tmbundle:
|
||||
- text.haml
|
||||
vendor/grammars/ruby-slim.tmbundle:
|
||||
@@ -490,8 +506,8 @@ vendor/grammars/ruby.tmbundle:
|
||||
- source.ruby
|
||||
- text.html.erb
|
||||
vendor/grammars/sas.tmbundle:
|
||||
- source.SASLog
|
||||
- source.sas
|
||||
- source.sas_log
|
||||
vendor/grammars/sass-textmate-bundle:
|
||||
- source.sass
|
||||
vendor/grammars/scala.tmbundle:
|
||||
|
||||
@@ -56,6 +56,7 @@ module Linguist
|
||||
generated_net_specflow_feature_file? ||
|
||||
composer_lock? ||
|
||||
node_modules? ||
|
||||
npm_shrinkwrap? ||
|
||||
godeps? ||
|
||||
generated_by_zephir? ||
|
||||
minified_files? ||
|
||||
@@ -109,11 +110,11 @@ module Linguist
|
||||
#
|
||||
# We assume that if one of the last 2 lines starts with a source map
|
||||
# reference, then the current file was generated from other files.
|
||||
#
|
||||
#
|
||||
# We use the last 2 lines because the last line might be empty.
|
||||
#
|
||||
#
|
||||
# We only handle JavaScript, no CSS support yet.
|
||||
#
|
||||
#
|
||||
# Returns true or false.
|
||||
def has_source_map?
|
||||
return false unless extname.downcase == '.js'
|
||||
@@ -303,6 +304,13 @@ module Linguist
|
||||
!!name.match(/node_modules\//)
|
||||
end
|
||||
|
||||
# Internal: Is the blob a generated npm shrinkwrap file.
|
||||
#
|
||||
# Returns true or false.
|
||||
def npm_shrinkwrap?
|
||||
!!name.match(/npm-shrinkwrap\.json/)
|
||||
end
|
||||
|
||||
# Internal: Is the blob part of Godeps/,
|
||||
# which are not meant for humans in pull requests.
|
||||
#
|
||||
@@ -355,14 +363,14 @@ module Linguist
|
||||
# on the first line.
|
||||
#
|
||||
# GFortran module files contain:
|
||||
# GFORTRAN module version 'x' created from
|
||||
# GFORTRAN module version 'x' created from
|
||||
# on the first line.
|
||||
#
|
||||
# Return true of false
|
||||
def generated_module?
|
||||
return false unless extname == '.mod'
|
||||
return false unless lines.count > 1
|
||||
return lines[0].include?("PCBNEW-LibModule-V") ||
|
||||
return lines[0].include?("PCBNEW-LibModule-V") ||
|
||||
lines[0].include?("GFORTRAN module version '")
|
||||
end
|
||||
|
||||
|
||||
@@ -382,7 +382,7 @@ module Linguist
|
||||
elsif /(alter module)|(language sql)|(begin( NOT)+ atomic)/i.match(data) || /signal SQLSTATE '[0-9]+'/i.match(data)
|
||||
#IBM db2
|
||||
Language["SQLPL"]
|
||||
elsif /pragma|\$\$PLSQL_|XMLTYPE|sysdate|systimestamp|\.nextval|connect by|AUTHID (DEFINER|CURRENT_USER)/i.match(data) || /constructor\W+function/i.match(data)
|
||||
elsif /\$\$PLSQL_|XMLTYPE|sysdate|systimestamp|\.nextval|connect by|AUTHID (DEFINER|CURRENT_USER)/i.match(data) || /constructor\W+function/i.match(data)
|
||||
#Oracle
|
||||
Language["PLSQL"]
|
||||
elsif ! /begin|boolean|package|exception/i.match(data)
|
||||
@@ -391,6 +391,20 @@ module Linguist
|
||||
end
|
||||
end
|
||||
|
||||
disambiguate ".srt" do |data|
|
||||
if /^(\d{2}:\d{2}:\d{2},\d{3})\s*(-->)\s*(\d{2}:\d{2}:\d{2},\d{3})$/.match(data)
|
||||
Language["SubRip Text"]
|
||||
end
|
||||
end
|
||||
|
||||
disambiguate ".t" do |data|
|
||||
if /^\s*%|^\s*var\s+\w+\s*:\s*\w+/.match(data)
|
||||
Language["Turing"]
|
||||
elsif /^\s*use\s+v6\s*;/.match(data)
|
||||
Language["Perl6"]
|
||||
end
|
||||
end
|
||||
|
||||
disambiguate ".toc" do |data|
|
||||
if /^## |@no-lib-strip@/.match(data)
|
||||
Language["World of Warcraft Addon Data"]
|
||||
|
||||
@@ -75,6 +75,10 @@ APL:
|
||||
extensions:
|
||||
- .apl
|
||||
- .dyalog
|
||||
interpreters:
|
||||
- apl
|
||||
- aplx
|
||||
- dyalog
|
||||
tm_scope: source.apl
|
||||
ace_mode: text
|
||||
|
||||
@@ -479,6 +483,13 @@ COBOL:
|
||||
- .cpy
|
||||
ace_mode: cobol
|
||||
|
||||
COLLADA:
|
||||
type: data
|
||||
extensions:
|
||||
- .dae
|
||||
tm_scope: text.xml
|
||||
ace_mode: xml
|
||||
|
||||
CSS:
|
||||
type: markup
|
||||
tm_scope: source.css
|
||||
@@ -560,7 +571,7 @@ Clean:
|
||||
extensions:
|
||||
- .icl
|
||||
- .dcl
|
||||
tm_scope: none
|
||||
tm_scope: source.clean
|
||||
ace_mode: text
|
||||
|
||||
Click:
|
||||
@@ -694,7 +705,7 @@ Cpp-ObjDump:
|
||||
- .cxx-objdump
|
||||
tm_scope: objdump.x86asm
|
||||
aliases:
|
||||
- c++-objdumb
|
||||
- c++-objdump
|
||||
ace_mode: assembly_x86
|
||||
|
||||
Creole:
|
||||
@@ -702,7 +713,7 @@ Creole:
|
||||
wrap: true
|
||||
extensions:
|
||||
- .creole
|
||||
tm_scope: none
|
||||
tm_scope: text.html.creole
|
||||
ace_mode: text
|
||||
|
||||
Crystal:
|
||||
@@ -715,6 +726,34 @@ Crystal:
|
||||
interpreters:
|
||||
- crystal
|
||||
|
||||
Csound:
|
||||
type: programming
|
||||
aliases:
|
||||
- csound-orc
|
||||
extensions:
|
||||
- .orc
|
||||
- .udo
|
||||
tm_scope: source.csound
|
||||
ace_mode: text
|
||||
|
||||
Csound Document:
|
||||
type: programming
|
||||
aliases:
|
||||
- csound-csd
|
||||
extensions:
|
||||
- .csd
|
||||
tm_scope: source.csound-document
|
||||
ace_mode: text
|
||||
|
||||
Csound Score:
|
||||
type: programming
|
||||
aliases:
|
||||
- csound-sco
|
||||
extensions:
|
||||
- .sco
|
||||
tm_scope: source.csound-score
|
||||
ace_mode: text
|
||||
|
||||
Cucumber:
|
||||
type: programming
|
||||
extensions:
|
||||
@@ -1044,7 +1083,7 @@ Fantom:
|
||||
color: "#dbded5"
|
||||
extensions:
|
||||
- .fan
|
||||
tm_scope: source.fan
|
||||
tm_scope: none
|
||||
ace_mode: text
|
||||
|
||||
Filterscript:
|
||||
@@ -1128,7 +1167,7 @@ GAS:
|
||||
extensions:
|
||||
- .s
|
||||
- .ms
|
||||
tm_scope: none
|
||||
tm_scope: source.assembly
|
||||
ace_mode: assembly_x86
|
||||
|
||||
GDScript:
|
||||
@@ -1405,6 +1444,16 @@ HTML+Django:
|
||||
- htmldjango
|
||||
ace_mode: django
|
||||
|
||||
HTML+ECR:
|
||||
type: markup
|
||||
tm_scope: text.html.ecr
|
||||
group: HTML
|
||||
aliases:
|
||||
- ecr
|
||||
extensions:
|
||||
- .ecr
|
||||
ace_mode: text
|
||||
|
||||
HTML+EEX:
|
||||
type: markup
|
||||
tm_scope: text.html.elixir
|
||||
@@ -1621,6 +1670,8 @@ J:
|
||||
color: "#9EEDFF"
|
||||
extensions:
|
||||
- .ijs
|
||||
interpreters:
|
||||
- jconsole
|
||||
tm_scope: source.j
|
||||
ace_mode: text
|
||||
|
||||
@@ -1644,7 +1695,6 @@ JSON:
|
||||
- .json
|
||||
- .geojson
|
||||
- .JSON-tmLanguage
|
||||
- .lock
|
||||
- .topojson
|
||||
filenames:
|
||||
- .arcconfig
|
||||
@@ -1688,6 +1738,7 @@ Jade:
|
||||
type: markup
|
||||
extensions:
|
||||
- .jade
|
||||
- .pug
|
||||
tm_scope: text.jade
|
||||
ace_mode: jade
|
||||
|
||||
@@ -2113,6 +2164,7 @@ Makefile:
|
||||
- Makefile.in
|
||||
- Makefile.inc
|
||||
- makefile
|
||||
- makefile.sco
|
||||
- mkfile
|
||||
interpreters:
|
||||
- make
|
||||
@@ -2424,7 +2476,7 @@ Nu:
|
||||
- .nu
|
||||
filenames:
|
||||
- Nukefile
|
||||
tm_scope: source.scheme
|
||||
tm_scope: source.nu
|
||||
ace_mode: scheme
|
||||
interpreters:
|
||||
- nush
|
||||
@@ -3284,6 +3336,14 @@ SQLPL:
|
||||
- .sql
|
||||
- .db2
|
||||
|
||||
SRecode Template:
|
||||
type: markup
|
||||
color: "#348a34"
|
||||
tm_scope: source.lisp
|
||||
ace_mode: lisp
|
||||
extensions:
|
||||
- .srt
|
||||
|
||||
STON:
|
||||
type: data
|
||||
group: Smalltalk
|
||||
@@ -3533,6 +3593,13 @@ Stylus:
|
||||
tm_scope: source.stylus
|
||||
ace_mode: stylus
|
||||
|
||||
SubRip Text:
|
||||
type: data
|
||||
extensions:
|
||||
- .srt
|
||||
ace_mode: text
|
||||
tm_scope: text.srt
|
||||
|
||||
SuperCollider:
|
||||
type: programming
|
||||
color: "#46390b"
|
||||
@@ -3659,6 +3726,7 @@ Text:
|
||||
- INSTALL
|
||||
- LICENSE
|
||||
- NEWS
|
||||
- README.1ST
|
||||
- README.me
|
||||
- click.me
|
||||
- delete.me
|
||||
@@ -3685,11 +3753,11 @@ Thrift:
|
||||
|
||||
Turing:
|
||||
type: programming
|
||||
color: "#45f715"
|
||||
color: "#cf142b"
|
||||
extensions:
|
||||
- .t
|
||||
- .tu
|
||||
tm_scope: none
|
||||
tm_scope: source.turing
|
||||
ace_mode: text
|
||||
|
||||
Turtle:
|
||||
@@ -3855,6 +3923,20 @@ Vue:
|
||||
tm_scope: text.html.vue
|
||||
ace_mode: html
|
||||
|
||||
Wavefront Material:
|
||||
type: data
|
||||
extensions:
|
||||
- .mtl
|
||||
tm_scope: source.wavefront.mtl
|
||||
ace_mode: text
|
||||
|
||||
Wavefront Object:
|
||||
type: data
|
||||
extensions:
|
||||
- .obj
|
||||
tm_scope: source.wavefront.obj
|
||||
ace_mode: text
|
||||
|
||||
Web Ontology Language:
|
||||
type: markup
|
||||
color: "#9cc9dd"
|
||||
@@ -4142,6 +4224,8 @@ edn:
|
||||
fish:
|
||||
type: programming
|
||||
group: Shell
|
||||
interpreters:
|
||||
- fish
|
||||
extensions:
|
||||
- .fish
|
||||
tm_scope: source.fish
|
||||
|
||||
@@ -21,7 +21,7 @@ module Linguist
|
||||
def self.cache
|
||||
@cache ||= begin
|
||||
serializer = defined?(Yajl) ? Yajl : YAML
|
||||
serializer.load(File.read(PATH))
|
||||
serializer.load(File.read(PATH, encoding: 'utf-8'))
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
@@ -153,6 +153,9 @@
|
||||
- (^|/)tiny_mce([^.]*)\.js$
|
||||
- (^|/)tiny_mce/(langs|plugins|themes|utils)
|
||||
|
||||
# Ace Editor
|
||||
- (^|/)ace-builds/
|
||||
|
||||
# MathJax
|
||||
- (^|/)MathJax/
|
||||
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
module Linguist
|
||||
VERSION = "4.8.5"
|
||||
VERSION = "4.8.7"
|
||||
end
|
||||
|
||||
7
samples/APL/hashbang
Executable file
7
samples/APL/hashbang
Executable file
@@ -0,0 +1,7 @@
|
||||
#!/usr/local/bin/apl --script
|
||||
NEWLINE ← ⎕UCS 10
|
||||
HEADERS ← 'Content-Type: text/plain', NEWLINE
|
||||
HEADERS
|
||||
⍝ ⎕←HEADERS
|
||||
⍝ ⍕⎕TS
|
||||
)OFF
|
||||
21
samples/Csound Document/allglass.csd
Executable file
21
samples/Csound Document/allglass.csd
Executable file
@@ -0,0 +1,21 @@
|
||||
<CsoundSynthesizer>
|
||||
<CsInstruments>
|
||||
sr = 44100
|
||||
kr = 44100
|
||||
ksmps = 1
|
||||
nchnls = 2
|
||||
|
||||
; pvanal -n 512 -w 8 allglass1-L.wav allglass1-L.pvc
|
||||
; pvanal -n 512 -w 8 allglass1-R.wav allglass1-R.pvc
|
||||
instr 1
|
||||
ktime line 0, p3, 17.5018
|
||||
arL pvoc ktime, 1, "allglass1-L.pvc"
|
||||
arR pvoc ktime, 1, "allglass1-R.pvc"
|
||||
out arL, arR
|
||||
endin
|
||||
</CsInstruments>
|
||||
<CsScore>
|
||||
i 1 0 70.0073
|
||||
e
|
||||
</CsScore>
|
||||
</CsoundSynthesizer>
|
||||
34
samples/Csound Document/interp.csd
Executable file
34
samples/Csound Document/interp.csd
Executable file
@@ -0,0 +1,34 @@
|
||||
<CsoundSynthesizer>
|
||||
<CsInstruments>
|
||||
sr = 44100
|
||||
kr = 44100
|
||||
ksmps = 1
|
||||
nchnls = 2
|
||||
|
||||
; pvanal -n 1024 -w 2 partA-L.wav partA-L.pvc
|
||||
; pvanal -n 1024 -w 2 partA-R.wav partA-R.pvc
|
||||
; pvanal -n 1024 -w 2 partB.wav partB.pvc
|
||||
instr 1
|
||||
iscale = 1
|
||||
|
||||
ktimpnt1 line 0, iscale*(82196/44100), 82196/44100
|
||||
ktimpnt2 linseg 0, iscale*1.25, 0, iscale*(103518/44100), 103518/44100
|
||||
kfreqscale linseg 1, iscale*0.5, 1, iscale*1.6, 0.8
|
||||
kfreqinterpL linseg 0, iscale*0.25, 0, iscale*1.6, 1
|
||||
kampinterpL linseg 0, iscale*0.25, 0, iscale*1.6, 1
|
||||
kfreqinterpR linseg 0, iscale*0.5, 0, iscale*1.2, 1
|
||||
kampinterpR linseg 0, iscale*0.5, 0, iscale*1.2, 1
|
||||
|
||||
pvbufread ktimpnt1, "partB.pvc"
|
||||
apvcL pvinterp ktimpnt2, 1, "partA-L.pvc", kfreqscale, 1, 1, 1, 1-kfreqinterpL, 1-kampinterpL
|
||||
pvbufread ktimpnt1, "partB.pvc"
|
||||
apvcR pvinterp ktimpnt2, 1, "partA-R.pvc", kfreqscale, 1, 1, 1, 1-kfreqinterpR, 1-kampinterpR
|
||||
|
||||
outs apvcL*0.8, apvcR*0.8
|
||||
endin
|
||||
</CsInstruments>
|
||||
<CsScore>
|
||||
i 1 0 7
|
||||
e
|
||||
</CsScore>
|
||||
</CsoundSynthesizer>
|
||||
253
samples/Csound Document/test.csd
Normal file
253
samples/Csound Document/test.csd
Normal file
@@ -0,0 +1,253 @@
|
||||
<CsoundSynthesizer>
|
||||
<CsInstruments>
|
||||
// Csound single-line comments can be preceded by a pair of forward slashes...
|
||||
; ...or a semicolon.
|
||||
|
||||
/* Block comments begin with /* and end with */
|
||||
|
||||
// Orchestras begin with a header of audio parameters.
|
||||
nchnls = 1
|
||||
nchnls_i = 1
|
||||
sr = 44100
|
||||
0dbfs = 1
|
||||
ksmps = 10
|
||||
|
||||
// The control rate kr = sr / ksmps can be omitted when the number of audio
|
||||
// samples in a control period (ksmps) is set, but kr may appear in older
|
||||
// orchestras.
|
||||
kr = 4410
|
||||
|
||||
// Orchestras contain instruments. These begin with the keyword instr followed
|
||||
// by a comma-separated list of numbers or names of the instrument. Instruments
|
||||
// end at the endin keyword and cannot be nested.
|
||||
instr 1, N_a_M_e_, +Name
|
||||
// Instruments contain statements. Here is a typical statement:
|
||||
aSignal oscil 0dbfs, 440, 1
|
||||
// Statements are terminated with a newline (possibly preceded by a comment).
|
||||
// To write a statement on several lines, precede the newline with a
|
||||
// backslash.
|
||||
prints \
|
||||
"hello, world\n";comment
|
||||
|
||||
// Csound 6 introduced function syntax for opcodes with one or zero outputs.
|
||||
// The oscil statement above is the same as
|
||||
aSignal = oscil(0dbfs, 440, 1)
|
||||
|
||||
// Instruments can contain control structures.
|
||||
kNote = p3
|
||||
if (kNote == 0) then
|
||||
kFrequency = 220
|
||||
elseif kNote == 1 then // Parentheses around binary expressions are optional.
|
||||
kFrequency = 440
|
||||
endif
|
||||
|
||||
// Csound 6 introduced looping structures.
|
||||
iIndex = 0
|
||||
while iIndex < 5 do
|
||||
print iIndex
|
||||
iIndex += 1
|
||||
od
|
||||
iIndex = 0
|
||||
until iIndex >= 5 do
|
||||
print iIndex
|
||||
iIndex += 1
|
||||
enduntil
|
||||
// Both kinds of loops can be terminated by either od or enduntil.
|
||||
|
||||
// Single-line strings are enclosed in double-quotes.
|
||||
prints "string\\\r\n\t\""
|
||||
// Multi-line strings are enclosed in pairs of curly braces.
|
||||
prints {{
|
||||
hello,
|
||||
|
||||
world
|
||||
}}
|
||||
|
||||
// Instruments often end with a statement containing an output opcode.
|
||||
outc aSignal
|
||||
endin
|
||||
|
||||
// Orchestras can also contain user-defined opcodes (UDOs). Here is an
|
||||
// oscillator with one audio-rate output and two control-rate inputs:
|
||||
opcode anOscillator, a, kk
|
||||
kAmplitude, kFrequency xin
|
||||
aSignal vco2 kAmplitude, kFrequency
|
||||
xout aSignal
|
||||
endop
|
||||
instr TestOscillator
|
||||
outc(anOscillator(0dbfs, 110))
|
||||
endin
|
||||
|
||||
// Python can be executed in Csound
|
||||
// <https://csound.github.io/docs/manual/pyrun.html>. So can Lua
|
||||
// <https://csound.github.io/docs/manual/lua.html>.
|
||||
pyruni {{
|
||||
import random
|
||||
|
||||
pool = [(1 + i / 10.0) ** 1.2 for i in range(100)]
|
||||
|
||||
def get_number_from_pool(n, p):
|
||||
if random.random() < p:
|
||||
i = int(random.random() * len(pool))
|
||||
pool[i] = n;
|
||||
return random.choice(pool)
|
||||
}}
|
||||
|
||||
// The Csound preprocessor supports conditional compilation and including files.
|
||||
#ifdef DEBUG
|
||||
#undef DEBUG
|
||||
#include "filename.orc"
|
||||
#endif
|
||||
|
||||
// The preprocessor also supports object- and function-like macros. This is an
|
||||
// object-like macro that defines a number:
|
||||
#define A_HZ #440#
|
||||
|
||||
// This is a function-like macro:
|
||||
#define OSCIL_MACRO(VOLUME'FREQUENCY'TABLE) #oscil $VOLUME, $FREQUENCY, $TABLE#
|
||||
|
||||
// Bodies of macros are enclosed in # and can contain newlines. The arguments of
|
||||
// function-like macros are separated by single-quotes. Uses of macros are
|
||||
// prefixed with a dollar sign.
|
||||
instr TestMacro
|
||||
aSignal $OSCIL_MACRO(1'$A_HZ'1)
|
||||
// Not unlike PHP, macros expand in double-quoted strings.
|
||||
prints "The frequency of the oscillator is $A_HZ Hz.\n"
|
||||
out aSignal
|
||||
endin
|
||||
|
||||
// Here are other things to note about Csound.
|
||||
|
||||
// There are two bitwise NOT operators, ~ and ¬ (U+00AC). The latter is common
|
||||
// on keyboards in the United Kingdom
|
||||
// <https://en.wikipedia.org/wiki/British_and_American_keyboards>.
|
||||
instr TestBitwiseNOT
|
||||
print ~42
|
||||
print ¬42
|
||||
endin
|
||||
|
||||
// Csound uses # for bitwise XOR, which the Csound manual calls bitwise
|
||||
// non-equivalence <https://csound.github.io/docs/manual/opnonequiv.html>.
|
||||
instr TestBitwiseXOR
|
||||
print 0 # 0
|
||||
print 0 # 1
|
||||
print 1 # 0
|
||||
print 1 # 1
|
||||
endin
|
||||
|
||||
// Loops and if-then statements are relatively recent additions to Csound. There
|
||||
// are many flow-control opcodes that involve goto and labels.
|
||||
instr TestGoto
|
||||
// This...
|
||||
if p3 > 0 goto if_label
|
||||
goto else_label
|
||||
if_label:
|
||||
prints "if branch\n"
|
||||
goto endif_label
|
||||
else_label:
|
||||
prints "else branch\n"
|
||||
endif_label:
|
||||
|
||||
// ...is the same as this.
|
||||
if p3 > 0 then
|
||||
prints "if branch\n"
|
||||
else
|
||||
prints "else branch\n"
|
||||
endif
|
||||
|
||||
// This...
|
||||
iIndex = 0
|
||||
loop_label:
|
||||
print iIndex
|
||||
iIndex += 1
|
||||
if iIndex < 10 goto loop_label
|
||||
|
||||
// ...is the same as this...
|
||||
iIndex = 0
|
||||
loop_lt_label:
|
||||
print iIndex
|
||||
loop_lt iIndex, 1, 10, loop_lt_label
|
||||
|
||||
// ...and this.
|
||||
iIndex = 0
|
||||
while iIndex < 10 do
|
||||
print iIndex
|
||||
iIndex += 1
|
||||
od
|
||||
endin
|
||||
|
||||
// The prints and printks opcodes
|
||||
// <https://github.com/csound/csound/blob/develop/OOps/ugrw1.c#L831>, arguably
|
||||
// the primary methods of logging output, treat certain sequences of characters
|
||||
// different from printf in C.
|
||||
instr TestPrints
|
||||
// ^ prints an ESCAPE character (U+001B), not a CIRCUMFLEX ACCENT character
|
||||
// (U+005E). ^^ prints a CIRCUMFLEX ACCENT.
|
||||
prints "^^\n"
|
||||
// ~ prints an ESCAPE character (U+001B) followed by a [, not a TILDE
|
||||
// character (U+007E). ~~ prints a TILDE.
|
||||
prints "~~\n"
|
||||
// \A, \B, \N, \R, and \T correspond to the escaped lowercase characters (that
|
||||
// is, BELL (U+0007), BACKSPACE (U+0008), new line (U+000A), CARRIAGE RETURN
|
||||
// (U+000D), and tab (U+0009)).
|
||||
prints "\T\R\N"
|
||||
// %n, %r, and %t are the same as \n, \r, and \t, as are %N, %R, and %T.
|
||||
prints "%t%r%n"
|
||||
// %! prints a semicolon. This is a hold-over from old versions of Csound that
|
||||
// allowed comments to begin in strings.
|
||||
prints "; %!\n"
|
||||
endin
|
||||
|
||||
// The arguments of function-like macros can be separated by # instead of '.
|
||||
// These two lines define the same macro.
|
||||
#define OSCIL_MACRO(VOLUME'FREQUENCY'TABLE) #oscil $VOLUME, $FREQUENCY, $TABLE#
|
||||
#define OSCIL_MACRO(VOLUME#FREQUENCY#TABLE) #oscil $VOLUME, $FREQUENCY, $TABLE#
|
||||
|
||||
// Uses of macros can optionally be suffixed with a period.
|
||||
instr TestMacroPeriodSuffix
|
||||
aSignal $OSCIL_MACRO.(1'$A_HZ'1)
|
||||
prints "The frequency of the oscillator is $A_HZ.Hz.\n"
|
||||
out aSignal
|
||||
endin
|
||||
|
||||
// Csound has @ and @@ operator-like macros that, when followed by a literal
|
||||
// non-negative integer, expand to the next power of 2 and the next power of 2
|
||||
// plus 1:
|
||||
// @x = 2^(ceil(log2(x + 1))), x >= 0
|
||||
// @@0 = 2
|
||||
// @@x = 2^(ceil(log2(x))) + 1, x > 0
|
||||
instr TestAt
|
||||
prints "%d %2d %2d\n", 0, @0, @@0
|
||||
prints "%d %2d %2d\n", 1, @1, @@1
|
||||
prints "%d %2d %2d\n", 2, @2, @@2
|
||||
prints "%d %2d %2d\n", 3, @3, @@3
|
||||
prints "%d %2d %2d\n", 4, @4, @@4
|
||||
prints "%d %2d %2d\n", 5, @5, @@5
|
||||
prints "%d %2d %2d\n", 6, @6, @@6
|
||||
prints "%d %2d %2d\n", 7, @7, @@7
|
||||
prints "%d %2d %2d\n", 8, @8, @@8
|
||||
prints "%d %2d %2d\n", 9, @9, @@9
|
||||
endin
|
||||
|
||||
// Including newlines in macros can lead to confusing code.
|
||||
instr MacroAbuse
|
||||
if 1 == 1 then
|
||||
prints "on\n"
|
||||
#define FOO#
|
||||
BAR
|
||||
#endif // This ends the if block. It is not a preprocessor directive.
|
||||
endin
|
||||
</CsInstruments>
|
||||
<CsScore>
|
||||
f 1 0 16384 10 1
|
||||
i "N_a_M_e_" 0 2
|
||||
i "TestOscillator" 2 2
|
||||
i "TestBitwiseNOT" 0 1
|
||||
i "TestBitwiseXOR" 0 1
|
||||
i "TestGoto" 0 1
|
||||
i "TestMacroPeriodSuffix" 4 1
|
||||
i "TestAt" 0 1
|
||||
i "MacroAbuse" 0 1
|
||||
e
|
||||
</CsScore>
|
||||
</CsoundSynthesizer>
|
||||
2
samples/Csound Score/allglass.sco
Executable file
2
samples/Csound Score/allglass.sco
Executable file
@@ -0,0 +1,2 @@
|
||||
i 1 0 70.0073
|
||||
e
|
||||
2
samples/Csound Score/interp.sco
Executable file
2
samples/Csound Score/interp.sco
Executable file
@@ -0,0 +1,2 @@
|
||||
i 1 0 7
|
||||
e
|
||||
10
samples/Csound Score/test.sco
Normal file
10
samples/Csound Score/test.sco
Normal file
@@ -0,0 +1,10 @@
|
||||
f 1 0 16384 10 1
|
||||
i "N_a_M_e_" 0 2
|
||||
i "TestOscillator" 2 2
|
||||
i "TestBitwiseNOT" 0 1
|
||||
i "TestBitwiseXOR" 0 1
|
||||
i "TestGoto" 0 1
|
||||
i "TestMacroPeriodSuffix" 4 1
|
||||
i "TestAt" 0 1
|
||||
i "MacroAbuse" 0 1
|
||||
e
|
||||
13
samples/Csound/allglass.orc
Executable file
13
samples/Csound/allglass.orc
Executable file
@@ -0,0 +1,13 @@
|
||||
sr = 44100
|
||||
kr = 44100
|
||||
ksmps = 1
|
||||
nchnls = 2
|
||||
|
||||
; pvanal -n 512 -w 8 allglass1-L.wav allglass1-L.pvc
|
||||
; pvanal -n 512 -w 8 allglass1-R.wav allglass1-R.pvc
|
||||
instr 1
|
||||
ktime line 0, p3, 17.5018
|
||||
arL pvoc ktime, 1, "allglass1-L.pvc"
|
||||
arR pvoc ktime, 1, "allglass1-R.pvc"
|
||||
out arL, arR
|
||||
endin
|
||||
26
samples/Csound/interp.orc
Executable file
26
samples/Csound/interp.orc
Executable file
@@ -0,0 +1,26 @@
|
||||
sr = 44100
|
||||
kr = 44100
|
||||
ksmps = 1
|
||||
nchnls = 2
|
||||
|
||||
; pvanal -n 1024 -w 2 partA-L.wav partA-L.pvc
|
||||
; pvanal -n 1024 -w 2 partA-R.wav partA-R.pvc
|
||||
; pvanal -n 1024 -w 2 partB.wav partB.pvc
|
||||
instr 1
|
||||
iscale = 1
|
||||
|
||||
ktimpnt1 line 0, iscale*(82196/44100), 82196/44100
|
||||
ktimpnt2 linseg 0, iscale*1.25, 0, iscale*(103518/44100), 103518/44100
|
||||
kfreqscale linseg 1, iscale*0.5, 1, iscale*1.6, 0.8
|
||||
kfreqinterpL linseg 0, iscale*0.25, 0, iscale*1.6, 1
|
||||
kampinterpL linseg 0, iscale*0.25, 0, iscale*1.6, 1
|
||||
kfreqinterpR linseg 0, iscale*0.5, 0, iscale*1.2, 1
|
||||
kampinterpR linseg 0, iscale*0.5, 0, iscale*1.2, 1
|
||||
|
||||
pvbufread ktimpnt1, "partB.pvc"
|
||||
apvcL pvinterp ktimpnt2, 1, "partA-L.pvc", kfreqscale, 1, 1, 1, 1-kfreqinterpL, 1-kampinterpL
|
||||
pvbufread ktimpnt1, "partB.pvc"
|
||||
apvcR pvinterp ktimpnt2, 1, "partA-R.pvc", kfreqscale, 1, 1, 1, 1-kfreqinterpR, 1-kampinterpR
|
||||
|
||||
outs apvcL*0.8, apvcR*0.8
|
||||
endin
|
||||
250
samples/Csound/test.orc
Normal file
250
samples/Csound/test.orc
Normal file
@@ -0,0 +1,250 @@
|
||||
// Csound single-line comments can be preceded by a pair of forward slashes...
|
||||
; ...or a semicolon.
|
||||
|
||||
/* Block comments begin with /* and end with */
|
||||
|
||||
// Orchestras begin with a header of audio parameters.
|
||||
nchnls = 1
|
||||
nchnls_i = 1
|
||||
sr = 44100
|
||||
0dbfs = 1
|
||||
ksmps = 10
|
||||
|
||||
// The control rate kr = sr / ksmps can be omitted when the number of audio
|
||||
// samples in a control period (ksmps) is set, but kr may appear in older
|
||||
// orchestras.
|
||||
kr = 4410
|
||||
|
||||
// Orchestras contain instruments. These begin with the keyword instr followed
|
||||
// by a comma-separated list of numbers or names of the instrument. Instruments
|
||||
// end at the endin keyword and cannot be nested.
|
||||
instr 1, N_a_M_e_, +Name
|
||||
// Instruments contain statements. Here is a typical statement:
|
||||
aSignal oscil 0dbfs, 440, 1
|
||||
// Statements are terminated with a newline (possibly preceded by a comment).
|
||||
// To write a statement on several lines, precede the newline with a
|
||||
// backslash.
|
||||
prints \
|
||||
"hello, world\n";comment
|
||||
|
||||
// Csound 6 introduced function syntax for opcodes with one or zero outputs.
|
||||
// The oscil statement above is the same as
|
||||
aSignal = oscil(0dbfs, 440, 1)
|
||||
|
||||
// Instruments can contain control structures.
|
||||
kNote = p3
|
||||
if (kNote == 0) then
|
||||
kFrequency = 220
|
||||
elseif kNote == 1 then // Parentheses around binary expressions are optional.
|
||||
kFrequency = 440
|
||||
endif
|
||||
|
||||
// Csound 6 introduced looping structures.
|
||||
iIndex = 0
|
||||
while iIndex < 5 do
|
||||
print iIndex
|
||||
iIndex += 1
|
||||
od
|
||||
iIndex = 0
|
||||
until iIndex >= 5 do
|
||||
print iIndex
|
||||
iIndex += 1
|
||||
enduntil
|
||||
// Both kinds of loops can be terminated by either od or enduntil.
|
||||
|
||||
// Single-line strings are enclosed in double-quotes.
|
||||
prints "string\\\r\n\t\""
|
||||
// Multi-line strings are enclosed in pairs of curly braces.
|
||||
prints {{
|
||||
hello,
|
||||
|
||||
world
|
||||
}}
|
||||
|
||||
// Instruments often end with a statement containing an output opcode.
|
||||
outc aSignal
|
||||
endin
|
||||
|
||||
// Orchestras can also contain user-defined opcodes (UDOs). Here is an
|
||||
// oscillator with one audio-rate output and two control-rate inputs:
|
||||
opcode anOscillator, a, kk
|
||||
kAmplitude, kFrequency xin
|
||||
aSignal vco2 kAmplitude, kFrequency
|
||||
xout aSignal
|
||||
endop
|
||||
instr TestOscillator
|
||||
outc(anOscillator(0dbfs, 110))
|
||||
endin
|
||||
|
||||
// Python can be executed in Csound
|
||||
// <https://csound.github.io/docs/manual/pyrun.html>. So can Lua
|
||||
// <https://csound.github.io/docs/manual/lua.html>.
|
||||
pyruni {{
|
||||
import random
|
||||
|
||||
pool = [(1 + i / 10.0) ** 1.2 for i in range(100)]
|
||||
|
||||
def get_number_from_pool(n, p):
|
||||
if random.random() < p:
|
||||
i = int(random.random() * len(pool))
|
||||
pool[i] = n;
|
||||
return random.choice(pool)
|
||||
}}
|
||||
|
||||
// The Csound preprocessor supports conditional compilation and including files.
|
||||
#ifdef DEBUG
|
||||
#undef DEBUG
|
||||
#include "filename.orc"
|
||||
#endif
|
||||
|
||||
// The preprocessor also supports object- and function-like macros. This is an
|
||||
// object-like macro that defines a number:
|
||||
#define A_HZ #440#
|
||||
|
||||
// This is a function-like macro:
|
||||
#define OSCIL_MACRO(VOLUME'FREQUENCY'TABLE) #oscil $VOLUME, $FREQUENCY, $TABLE#
|
||||
|
||||
// Bodies of macros are enclosed in # and can contain newlines. The arguments of
|
||||
// function-like macros are separated by single-quotes. Uses of macros are
|
||||
// prefixed with a dollar sign.
|
||||
instr TestMacro
|
||||
aSignal $OSCIL_MACRO(1'$A_HZ'1)
|
||||
// Not unlike PHP, macros expand in double-quoted strings.
|
||||
prints "The frequency of the oscillator is $A_HZ Hz.\n"
|
||||
out aSignal
|
||||
endin
|
||||
|
||||
// Here are other things to note about Csound.
|
||||
|
||||
// There are two bitwise NOT operators, ~ and ¬ (U+00AC). The latter is common
|
||||
// on keyboards in the United Kingdom
|
||||
// <https://en.wikipedia.org/wiki/British_and_American_keyboards>.
|
||||
instr TestBitwiseNOT
|
||||
print ~42
|
||||
print ¬42
|
||||
endin
|
||||
|
||||
// Csound uses # for bitwise XOR, which the Csound manual calls bitwise
|
||||
// non-equivalence <https://csound.github.io/docs/manual/opnonequiv.html>.
|
||||
instr TestBitwiseXOR
|
||||
print 0 # 0
|
||||
print 0 # 1
|
||||
print 1 # 0
|
||||
print 1 # 1
|
||||
endin
|
||||
|
||||
// Loops and if-then statements are relatively recent additions to Csound. There
|
||||
// are many flow-control opcodes that involve goto and labels.
|
||||
instr TestGoto
|
||||
// This...
|
||||
if p3 > 0 goto if_label
|
||||
goto else_label
|
||||
if_label:
|
||||
prints "if branch\n"
|
||||
goto endif_label
|
||||
else_label:
|
||||
prints "else branch\n"
|
||||
endif_label:
|
||||
|
||||
// ...is the same as this.
|
||||
if p3 > 0 then
|
||||
prints "if branch\n"
|
||||
else
|
||||
prints "else branch\n"
|
||||
endif
|
||||
|
||||
// This...
|
||||
iIndex = 0
|
||||
loop_label:
|
||||
print iIndex
|
||||
iIndex += 1
|
||||
if iIndex < 10 goto loop_label
|
||||
|
||||
// ...is the same as this...
|
||||
iIndex = 0
|
||||
loop_lt_label:
|
||||
print iIndex
|
||||
loop_lt iIndex, 1, 10, loop_lt_label
|
||||
|
||||
// ...and this.
|
||||
iIndex = 0
|
||||
while iIndex < 10 do
|
||||
print iIndex
|
||||
iIndex += 1
|
||||
od
|
||||
endin
|
||||
|
||||
// The prints and printks opcodes
|
||||
// <https://github.com/csound/csound/blob/develop/OOps/ugrw1.c#L831>, arguably
|
||||
// the primary methods of logging output, treat certain sequences of characters
|
||||
// different from printf in C.
|
||||
instr TestPrints
|
||||
// ^ prints an ESCAPE character (U+001B), not a CIRCUMFLEX ACCENT character
|
||||
// (U+005E). ^^ prints a CIRCUMFLEX ACCENT.
|
||||
prints "^^\n"
|
||||
// ~ prints an ESCAPE character (U+001B) followed by a [, not a TILDE
|
||||
// character (U+007E). ~~ prints a TILDE.
|
||||
prints "~~\n"
|
||||
// \A, \B, \N, \R, and \T correspond to the escaped lowercase characters (that
|
||||
// is, BELL (U+0007), BACKSPACE (U+0008), new line (U+000A), CARRIAGE RETURN
|
||||
// (U+000D), and tab (U+0009)).
|
||||
prints "\T\R\N"
|
||||
// %n, %r, and %t are the same as \n, \r, and \t, as are %N, %R, and %T.
|
||||
prints "%t%r%n"
|
||||
// %! prints a semicolon. This is a hold-over from old versions of Csound that
|
||||
// allowed comments to begin in strings.
|
||||
prints "; %!\n"
|
||||
endin
|
||||
|
||||
// The arguments of function-like macros can be separated by # instead of '.
|
||||
// These two lines define the same macro.
|
||||
#define OSCIL_MACRO(VOLUME'FREQUENCY'TABLE) #oscil $VOLUME, $FREQUENCY, $TABLE#
|
||||
#define OSCIL_MACRO(VOLUME#FREQUENCY#TABLE) #oscil $VOLUME, $FREQUENCY, $TABLE#
|
||||
|
||||
// Uses of macros can optionally be suffixed with a period.
|
||||
instr TestMacroPeriodSuffix
|
||||
aSignal $OSCIL_MACRO.(1'$A_HZ'1)
|
||||
prints "The frequency of the oscillator is $A_HZ.Hz.\n"
|
||||
out aSignal
|
||||
endin
|
||||
|
||||
// Csound has @ and @@ operator-like macros that, when followed by a literal
|
||||
// non-negative integer, expand to the next power of 2 and the next power of 2
|
||||
// plus 1:
|
||||
// @x = 2^(ceil(log2(x + 1))), x >= 0
|
||||
// @@0 = 2
|
||||
// @@x = 2^(ceil(log2(x))) + 1, x > 0
|
||||
instr TestAt
|
||||
prints "%d %2d %2d\n", 0, @0, @@0
|
||||
prints "%d %2d %2d\n", 1, @1, @@1
|
||||
prints "%d %2d %2d\n", 2, @2, @@2
|
||||
prints "%d %2d %2d\n", 3, @3, @@3
|
||||
prints "%d %2d %2d\n", 4, @4, @@4
|
||||
prints "%d %2d %2d\n", 5, @5, @@5
|
||||
prints "%d %2d %2d\n", 6, @6, @@6
|
||||
prints "%d %2d %2d\n", 7, @7, @@7
|
||||
prints "%d %2d %2d\n", 8, @8, @@8
|
||||
prints "%d %2d %2d\n", 9, @9, @@9
|
||||
endin
|
||||
|
||||
// Including newlines in macros can lead to confusing code.
|
||||
instr MacroAbuse
|
||||
if 1 == 1 then
|
||||
prints "on\n"
|
||||
#define FOO#
|
||||
BAR
|
||||
#endif // This ends the if block. It is not a preprocessor directive.
|
||||
endin
|
||||
|
||||
scoreline_i {{
|
||||
f 1 0 16384 10 1
|
||||
i "N_a_M_e_" 0 2
|
||||
i "TestOscillator" 2 2
|
||||
i "TestBitwiseNOT" 0 1
|
||||
i "TestBitwiseXOR" 0 1
|
||||
i "TestGoto" 0 1
|
||||
i "TestMacroPeriodSuffix" 4 1
|
||||
i "TestAt" 0 1
|
||||
i "MacroAbuse" 0 1
|
||||
e
|
||||
}}
|
||||
5
samples/HTML+ECR/greeting.ecr
Normal file
5
samples/HTML+ECR/greeting.ecr
Normal file
@@ -0,0 +1,5 @@
|
||||
<% if @name %>
|
||||
Greeting, <%= @name %>!
|
||||
<% else %>
|
||||
Greeting!
|
||||
<% end %>
|
||||
3
samples/J/hashbang
Executable file
3
samples/J/hashbang
Executable file
@@ -0,0 +1,3 @@
|
||||
#!/bin/jconsole
|
||||
echo 'Hello, GitHub!'
|
||||
exit ''
|
||||
9
samples/Jade/hello.pug
Normal file
9
samples/Jade/hello.pug
Normal file
@@ -0,0 +1,9 @@
|
||||
doctype html
|
||||
html
|
||||
head
|
||||
meta(charset='utf-8')
|
||||
link(rel='stylesheet', type='text/css', href='main.css')
|
||||
title Hello Pug
|
||||
body
|
||||
#text
|
||||
include page
|
||||
226
samples/Makefile/filenames/makefile.sco
Normal file
226
samples/Makefile/filenames/makefile.sco
Normal file
@@ -0,0 +1,226 @@
|
||||
# makefile for SCO OSr5 ELF and Unixware 7 with Native cc
|
||||
# Contributed by Mike Hopkirk (hops@sco.com) modified from Makefile.lnx
|
||||
# force ELF build dynamic linking, SONAME setting in lib and RPATH in app
|
||||
# Copyright (C) 2002, 2006, 2010-2014 Glenn Randers-Pehrson
|
||||
# Copyright (C) 1998 Greg Roelofs
|
||||
# Copyright (C) 1996, 1997 Andreas Dilger
|
||||
#
|
||||
# This code is released under the libpng license.
|
||||
# For conditions of distribution and use, see the disclaimer
|
||||
# and license in png.h
|
||||
|
||||
# Library name:
|
||||
LIBNAME = libpng16
|
||||
PNGMAJ = 16
|
||||
|
||||
# Shared library names:
|
||||
LIBSO=$(LIBNAME).so
|
||||
LIBSOMAJ=$(LIBNAME).so.$(PNGMAJ)
|
||||
LIBSOREL=$(LIBSOMAJ).$(RELEASE)
|
||||
OLDSO=libpng.so
|
||||
|
||||
# Utilities:
|
||||
CC=cc
|
||||
AR_RC=ar rc
|
||||
MKDIR_P=mkdir
|
||||
LN_SF=ln -f -s
|
||||
RANLIB=echo
|
||||
CP=cp
|
||||
RM_F=/bin/rm -f
|
||||
|
||||
# where make install puts libpng.a, $(OLDSO)*, and png.h
|
||||
prefix=/usr/local
|
||||
exec_prefix=$(prefix)
|
||||
|
||||
# Where the zlib library and include files are located
|
||||
#ZLIBLIB=/usr/local/lib
|
||||
#ZLIBINC=/usr/local/include
|
||||
ZLIBLIB=../zlib
|
||||
ZLIBINC=../zlib
|
||||
|
||||
CPPFLAGS=-I$(ZLIBINC)
|
||||
CFLAGS= -dy -belf -O3
|
||||
LDFLAGS=-L. -L$(ZLIBLIB) -lpng16 -lz -lm
|
||||
|
||||
INCPATH=$(prefix)/include
|
||||
LIBPATH=$(exec_prefix)/lib
|
||||
MANPATH=$(prefix)/man
|
||||
BINPATH=$(exec_prefix)/bin
|
||||
|
||||
# override DESTDIR= on the make install command line to easily support
|
||||
# installing into a temporary location. Example:
|
||||
#
|
||||
# make install DESTDIR=/tmp/build/libpng
|
||||
#
|
||||
# If you're going to install into a temporary location
|
||||
# via DESTDIR, $(DESTDIR)$(prefix) must already exist before
|
||||
# you execute make install.
|
||||
DESTDIR=
|
||||
|
||||
DB=$(DESTDIR)$(BINPATH)
|
||||
DI=$(DESTDIR)$(INCPATH)
|
||||
DL=$(DESTDIR)$(LIBPATH)
|
||||
DM=$(DESTDIR)$(MANPATH)
|
||||
|
||||
# Pre-built configuration
|
||||
# See scripts/pnglibconf.mak for more options
|
||||
PNGLIBCONF_H_PREBUILT = scripts/pnglibconf.h.prebuilt
|
||||
|
||||
OBJS = png.o pngset.o pngget.o pngrutil.o pngtrans.o pngwutil.o \
|
||||
pngread.o pngrio.o pngwio.o pngwrite.o pngrtran.o \
|
||||
pngwtran.o pngmem.o pngerror.o pngpread.o
|
||||
|
||||
OBJSDLL = $(OBJS:.o=.pic.o)
|
||||
|
||||
.SUFFIXES: .c .o .pic.o
|
||||
|
||||
.c.o:
|
||||
$(CC) -c $(CPPFLAGS) $(CFLAGS) -o $@ $<
|
||||
|
||||
.c.pic.o:
|
||||
$(CC) -c $(CPPFLAGS) $(CFLAGS) -KPIC -o $@ $*.c
|
||||
|
||||
all: libpng.a $(LIBSO) pngtest libpng.pc libpng-config
|
||||
|
||||
pnglibconf.h: $(PNGLIBCONF_H_PREBUILT)
|
||||
$(CP) $(PNGLIBCONF_H_PREBUILT) $@
|
||||
|
||||
libpng.a: $(OBJS)
|
||||
$(AR_RC) $@ $(OBJS)
|
||||
$(RANLIB) $@
|
||||
|
||||
libpng.pc:
|
||||
cat scripts/libpng.pc.in | sed -e s!@prefix@!$(prefix)! \
|
||||
-e s!@exec_prefix@!$(exec_prefix)! \
|
||||
-e s!@libdir@!$(LIBPATH)! \
|
||||
-e s!@includedir@!$(INCPATH)! \
|
||||
-e s!-lpng16!-lpng16\ -lz\ -lm! > libpng.pc
|
||||
|
||||
libpng-config:
|
||||
( cat scripts/libpng-config-head.in; \
|
||||
echo prefix=\"$(prefix)\"; \
|
||||
echo I_opts=\"-I$(INCPATH)/$(LIBNAME)\"; \
|
||||
echo ccopts=\"-belf\"; \
|
||||
echo L_opts=\"-L$(LIBPATH)\"; \
|
||||
echo libs=\"-lpng16 -lz -lm\"; \
|
||||
cat scripts/libpng-config-body.in ) > libpng-config
|
||||
chmod +x libpng-config
|
||||
|
||||
$(LIBSO): $(LIBSOMAJ)
|
||||
$(LN_SF) $(LIBSOMAJ) $(LIBSO)
|
||||
|
||||
$(LIBSOMAJ): $(OBJSDLL)
|
||||
$(CC) -G -Wl,-h,$(LIBSOMAJ) -o $(LIBSOMAJ) \
|
||||
$(OBJSDLL)
|
||||
|
||||
pngtest: pngtest.o $(LIBSO)
|
||||
LD_RUN_PATH=.:$(ZLIBLIB) $(CC) -o pngtest $(CFLAGS) pngtest.o $(LDFLAGS)
|
||||
|
||||
test: pngtest
|
||||
./pngtest
|
||||
|
||||
install-headers: png.h pngconf.h pnglibconf.h
|
||||
-@if [ ! -d $(DI) ]; then $(MKDIR_P) $(DI); fi
|
||||
-@if [ ! -d $(DI)/$(LIBNAME) ]; then $(MKDIR_P) $(DI)/$(LIBNAME); fi
|
||||
-@$(RM_F) $(DI)/png.h
|
||||
-@$(RM_F) $(DI)/pngconf.h
|
||||
-@$(RM_F) $(DI)/pnglibconf.h
|
||||
cp png.h pngconf.h pnglibconf.h $(DI)/$(LIBNAME)
|
||||
chmod 644 $(DI)/$(LIBNAME)/png.h $(DI)/$(LIBNAME)/pngconf.h $(DI)/$(LIBNAME)/pnglibconf.h
|
||||
-@$(RM_F) $(DI)/png.h $(DI)/pngconf.h $(DI)/pnglibconf.h
|
||||
-@$(RM_F) $(DI)/libpng
|
||||
(cd $(DI); $(LN_SF) $(LIBNAME) libpng; $(LN_SF) $(LIBNAME)/* .)
|
||||
|
||||
install-static: install-headers libpng.a
|
||||
-@if [ ! -d $(DL) ]; then $(MKDIR_P) $(DL); fi
|
||||
cp libpng.a $(DL)/$(LIBNAME).a
|
||||
chmod 644 $(DL)/$(LIBNAME).a
|
||||
-@$(RM_F) $(DL)/libpng.a
|
||||
(cd $(DL); $(LN_SF) $(LIBNAME).a libpng.a)
|
||||
|
||||
install-shared: install-headers $(LIBSOMAJ) libpng.pc
|
||||
-@if [ ! -d $(DL) ]; then $(MKDIR_P) $(DL); fi
|
||||
-@$(RM_F) $(DL)/$(LIBSO)
|
||||
-@$(RM_F) $(DL)/$(LIBSOREL)
|
||||
-@$(RM_F) $(DL)/$(OLDSO)
|
||||
cp $(LIBSOMAJ) $(DL)/$(LIBSOREL)
|
||||
chmod 755 $(DL)/$(LIBSOREL)
|
||||
(cd $(DL); \
|
||||
$(LN_SF) $(LIBSOREL) $(LIBSO); \
|
||||
$(LN_SF) $(LIBSO) $(OLDSO))
|
||||
-@if [ ! -d $(DL)/pkgconfig ]; then $(MKDIR_P) $(DL)/pkgconfig; fi
|
||||
-@$(RM_F) $(DL)/pkgconfig/$(LIBNAME).pc
|
||||
-@$(RM_F) $(DL)/pkgconfig/libpng.pc
|
||||
cp libpng.pc $(DL)/pkgconfig/$(LIBNAME).pc
|
||||
chmod 644 $(DL)/pkgconfig/$(LIBNAME).pc
|
||||
(cd $(DL)/pkgconfig; $(LN_SF) $(LIBNAME).pc libpng.pc)
|
||||
|
||||
install-man: libpng.3 libpngpf.3 png.5
|
||||
-@if [ ! -d $(DM) ]; then $(MKDIR_P) $(DM); fi
|
||||
-@if [ ! -d $(DM)/man3 ]; then $(MKDIR_P) $(DM)/man3; fi
|
||||
-@$(RM_F) $(DM)/man3/libpng.3
|
||||
-@$(RM_F) $(DM)/man3/libpngpf.3
|
||||
cp libpng.3 $(DM)/man3
|
||||
cp libpngpf.3 $(DM)/man3
|
||||
-@if [ ! -d $(DM)/man5 ]; then $(MKDIR_P) $(DM)/man5; fi
|
||||
-@$(RM_F) $(DM)/man5/png.5
|
||||
cp png.5 $(DM)/man5
|
||||
|
||||
install-config: libpng-config
|
||||
-@if [ ! -d $(DB) ]; then $(MKDIR_P) $(DB); fi
|
||||
-@$(RM_F) $(DB)/libpng-config
|
||||
-@$(RM_F) $(DB)/$(LIBNAME)-config
|
||||
cp libpng-config $(DB)/$(LIBNAME)-config
|
||||
chmod 755 $(DB)/$(LIBNAME)-config
|
||||
(cd $(DB); $(LN_SF) $(LIBNAME)-config libpng-config)
|
||||
|
||||
install: install-static install-shared install-man install-config
|
||||
|
||||
# If you installed in $(DESTDIR), test-installed won't work until you
|
||||
# move the library to its final location. Use test-dd to test it
|
||||
# before then.
|
||||
|
||||
test-dd:
|
||||
echo
|
||||
echo Testing installed dynamic shared library in $(DL).
|
||||
$(CC) -I$(DI) $(CPPFLAGS) \
|
||||
`$(BINPATH)/$(LIBNAME)-config --cflags` pngtest.c \
|
||||
-L$(DL) -L$(ZLIBLIB) \
|
||||
-o pngtestd `$(BINPATH)/$(LIBNAME)-config --ldflags`
|
||||
./pngtestd pngtest.png
|
||||
|
||||
test-installed:
|
||||
$(CC) $(CPPFLAGS) $(CFLAGS) \
|
||||
`$(BINPATH)/$(LIBNAME)-config --cflags` pngtest.c \
|
||||
-L$(ZLIBLIB) \
|
||||
-o pngtesti `$(BINPATH)/$(LIBNAME)-config --ldflags`
|
||||
./pngtesti pngtest.png
|
||||
|
||||
clean:
|
||||
$(RM_F) *.o libpng.a pngtest pngout.png libpng-config \
|
||||
$(LIBSO) $(LIBSOMAJ)* pngtest-static pngtesti \
|
||||
pnglibconf.h libpng.pc
|
||||
|
||||
DOCS = ANNOUNCE CHANGES INSTALL KNOWNBUG LICENSE README TODO Y2KINFO
|
||||
writelock:
|
||||
chmod a-w *.[ch35] $(DOCS) scripts/*
|
||||
|
||||
# DO NOT DELETE THIS LINE -- make depend depends on it.
|
||||
|
||||
png.o png.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
|
||||
pngerror.o pngerror.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
|
||||
pngrio.o pngrio.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
|
||||
pngwio.o pngwio.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
|
||||
pngmem.o pngmem.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
|
||||
pngset.o pngset.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
|
||||
pngget.o pngget.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
|
||||
pngread.o pngread.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
|
||||
pngrtran.o pngrtran.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
|
||||
pngrutil.o pngrutil.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
|
||||
pngtrans.o pngtrans.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
|
||||
pngwrite.o pngwrite.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
|
||||
pngwtran.o pngwtran.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
|
||||
pngwutil.o pngwutil.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
|
||||
pngpread.o pngpread.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
|
||||
|
||||
pngtest.o: png.h pngconf.h pnglibconf.h
|
||||
45
samples/SRecode Template/linguist.srt
Normal file
45
samples/SRecode Template/linguist.srt
Normal file
@@ -0,0 +1,45 @@
|
||||
;;; linguist.srt --- Template for linguist-example-mode
|
||||
|
||||
;; Not copyrighted whatsoever.
|
||||
;;
|
||||
;; GPL can bite my shiny metal ass.
|
||||
;;
|
||||
;; GitHub: 1
|
||||
;; Stallman: 0
|
||||
|
||||
set mode "default"
|
||||
|
||||
set comment_start ";"
|
||||
|
||||
set LICENSE "It's public domain, baby. This was written for the sole
|
||||
purpose of the format's inclusion and recognition by GitHub Linguist.
|
||||
This block of multiline text was added because every other .srt file
|
||||
I could find was GPL-licensed and had long-winded copyright blobs in
|
||||
the file's header. Also, check out my sick line-wrapping abilities."
|
||||
|
||||
set DOLLAR "$"
|
||||
|
||||
context file
|
||||
|
||||
|
||||
template license
|
||||
----
|
||||
{{LICENSE:srecode-comment-prefix}}
|
||||
----
|
||||
|
||||
|
||||
template filecomment :file :user :time
|
||||
----
|
||||
{{comment_start}} {{FILENAME}} --- {{^}}
|
||||
{{comment_prefix}} YUO WAN GPL?
|
||||
{{comment_prefix}}
|
||||
{{comment_prefix}} Copyright (C) {{YEAR}} {{?AUTHOR}}
|
||||
{{comment_prefix}}
|
||||
{{comment_prefix}} TUO BAD
|
||||
{{comment_prefix}} WE EXPAT PEOPLE
|
||||
{{comment_prefix}} {{EXPLETIVE}} YOU!
|
||||
{{>:copyright}}
|
||||
{{comment_end}}
|
||||
----
|
||||
|
||||
;; end
|
||||
@@ -0,0 +1,240 @@
|
||||
1
|
||||
00:00:01,250 --> 00:00:03,740
|
||||
Adding NCL language.
|
||||
|
||||
2
|
||||
00:00:04,600 --> 00:00:08,730
|
||||
Thanks for the pull request! Do you know if these files are NCL too?
|
||||
|
||||
3
|
||||
00:00:09,800 --> 00:00:13,700
|
||||
Those are poorly-named documentation files for NCL functions.
|
||||
|
||||
4
|
||||
00:00:14,560 --> 00:00:17,200
|
||||
- What's better?
|
||||
- This is better.
|
||||
|
||||
5
|
||||
00:00:18,500 --> 00:00:23,000
|
||||
- Would it be correct to recognise these files as text?
|
||||
- Yes.
|
||||
|
||||
6
|
||||
00:00:23,890 --> 00:00:30,000
|
||||
In that case, could you add "NCL" to the text entry in languages.yml too?
|
||||
|
||||
7
|
||||
00:00:30,540 --> 00:00:35,250
|
||||
I added the example to "Text" and updated the license in the grammar submodule.
|
||||
|
||||
8
|
||||
00:00:38,500 --> 00:00:42,360
|
||||
Cloning the submodule fails for me in local with this URL.
|
||||
|
||||
9
|
||||
00:00:42,360 --> 00:00:45,250
|
||||
Could you use Git or HTTPS...?
|
||||
|
||||
10
|
||||
00:00:46,810 --> 00:00:50,000
|
||||
I updated the grammar submodule link to HTTPS.
|
||||
|
||||
11
|
||||
00:00:51,100 --> 00:00:57,000
|
||||
It's still failing locally. I don't think you can just update the .gitmodules file.
|
||||
|
||||
12
|
||||
00:00:57,750 --> 00:01:03,000
|
||||
You'll probably have to remove the submodule and add it again to be sure.
|
||||
|
||||
13
|
||||
00:01:04,336 --> 00:01:11,800
|
||||
- I'll see first if it's not an issue on my side...
|
||||
- I removed the submodule and added it back with HTTPS.
|
||||
|
||||
14
|
||||
00:01:13,670 --> 00:01:18,000
|
||||
I tested the detection of NCL files with 2000 samples.
|
||||
|
||||
15
|
||||
00:01:18,000 --> 00:01:25,000
|
||||
The Bayesian classifier doesn't seem to be very good at distinguishing text from NCL.
|
||||
|
||||
16
|
||||
00:01:25,000 --> 00:01:30,740
|
||||
We could try to improve it by adding more samples, or we can define a new heuristic rule.
|
||||
|
||||
17
|
||||
00:01:31,300 --> 00:01:36,200
|
||||
- Do you want me to send you the sample files?
|
||||
- Yes, please do.
|
||||
|
||||
18
|
||||
00:01:37,500 --> 00:01:39,500
|
||||
In your inbox.
|
||||
|
||||
19
|
||||
00:01:41,285 --> 00:01:48,216
|
||||
- So if I manually go through these and sort out the errors, would that help?
|
||||
- Not really.
|
||||
|
||||
20
|
||||
00:01:48,540 --> 00:01:55,145
|
||||
It's a matter of keywords so there's not much to do there except for adding new samples.
|
||||
|
||||
21
|
||||
00:01:55,447 --> 00:02:02,000
|
||||
If adding a few more samples doesn't improve things, we'll see how to define a new heuristic rule.
|
||||
|
||||
22
|
||||
00:02:04,740 --> 00:02:09,600
|
||||
- I added quite a few NCL samples.
|
||||
- That's a bit over the top, isn't it?
|
||||
|
||||
23
|
||||
00:02:10,250 --> 00:02:16,000
|
||||
We currently can't add too many samples because of #2117.
|
||||
|
||||
24
|
||||
00:02:18,000 --> 00:02:20,830
|
||||
(sigh) I decreased the number of added samples.
|
||||
|
||||
25
|
||||
00:02:21,630 --> 00:02:25,300
|
||||
Could you test the detection results in local with the samples I gave you?
|
||||
|
||||
26
|
||||
00:02:26,000 --> 00:02:28,670
|
||||
- What is the command to run that test?
|
||||
- Here...
|
||||
|
||||
27
|
||||
00:02:28,716 --> 00:02:38,650
|
||||
[Coding intensifies]
|
||||
|
||||
28
|
||||
00:02:38,650 --> 00:02:43,330
|
||||
It is getting hung up on a false detection of Frege in one of the Text samples.
|
||||
|
||||
29
|
||||
00:02:43,540 --> 00:02:46,115
|
||||
Do you have any suggestions for implementing a heuristic?
|
||||
|
||||
30
|
||||
00:02:47,640 --> 00:02:55,200
|
||||
#2441 should fix this. In the meantime, you can change this in "test_heuristics.rb"
|
||||
|
||||
31
|
||||
00:02:55,165 --> 00:02:57,240
|
||||
Why did you have to change this?
|
||||
|
||||
32
|
||||
00:02:57,777 --> 00:03:04,480
|
||||
- It doesn't work for me unless I do that.
|
||||
- Hum, same for me. Arfon, does it work for you?
|
||||
|
||||
33
|
||||
00:03:04,920 --> 00:03:08,830
|
||||
Requiring linguist/language doesn't work for me either.
|
||||
|
||||
34
|
||||
00:03:09,300 --> 00:03:13,885
|
||||
We restructured some of the requires a while ago and I think this is just out-of-date code.
|
||||
|
||||
35
|
||||
00:03:14,065 --> 00:03:20,950
|
||||
From a large sample of known NCL files taken from Github, it's now predicting with about 98% accuracy.
|
||||
|
||||
36
|
||||
00:03:21,183 --> 00:03:28,000
|
||||
For a large sample of other files with the NCL extension, it is around 92%.
|
||||
|
||||
37
|
||||
00:03:27,880 --> 00:03:30,950
|
||||
From those, nearly all of the errors come from one GitHub repository,
|
||||
|
||||
38
|
||||
00:03:30,950 --> 00:03:34,160
|
||||
and they all contain the text strings, "The URL" and "The Title".
|
||||
|
||||
39
|
||||
00:03:35,660 --> 00:03:43,260
|
||||
- Do you mean 92% files correctly identified as text?
|
||||
- Yes, it correctly identifies 92% as text.
|
||||
|
||||
40
|
||||
00:03:44,000 --> 00:03:46,150
|
||||
I'd really like to see this dramatically reduced.
|
||||
|
||||
41
|
||||
00:03:46,150 --> 00:03:51,150
|
||||
What happens if we reduce to around 5 NCL sample files?
|
||||
|
||||
42
|
||||
00:03:51,150 --> 00:03:52,600
|
||||
Does Linguist still do a reasonable job?
|
||||
|
||||
43
|
||||
00:03:53,470 --> 00:03:58,190
|
||||
I reduced it to 16 NCL samples and 8 text samples.
|
||||
|
||||
44
|
||||
00:03:58,190 --> 00:04:01,720
|
||||
It correctly classifies my whole set of known NCL files.
|
||||
|
||||
45
|
||||
00:04:01,870 --> 00:04:05,730
|
||||
I tried with 5 samples but could not get the same level of accuracy.
|
||||
|
||||
46
|
||||
00:04:06,670 --> 00:04:10,400
|
||||
It incorrectly classifies all of the NCL files in this GitHub repository.
|
||||
|
||||
47
|
||||
00:04:11,130 --> 00:04:14,660
|
||||
All of these files contain the text strings, "THE_URL:" and "THE_TITLE:".
|
||||
|
||||
48
|
||||
00:04:14,660 --> 00:04:19,500
|
||||
It did not misclassify any other text-files with the extension NCL.
|
||||
|
||||
49
|
||||
00:04:19,970 --> 00:04:25,188
|
||||
With 100% accuracy? Does that mean it that the results are better with less samples??
|
||||
|
||||
50
|
||||
00:04:25,610 --> 00:04:31,190
|
||||
I also removed a sample text-file which should have been classified as an NCL file.
|
||||
|
||||
51
|
||||
00:04:31,000 --> 00:04:35,895
|
||||
I think that probably made most of the difference, although I didn't test it atomically.
|
||||
|
||||
52
|
||||
00:04:35,895 --> 00:04:38,370
|
||||
Okay, that makes more sense.
|
||||
|
||||
53
|
||||
00:04:39,515 --> 00:04:43,450
|
||||
I don't get the same results for the text files. Full results here.
|
||||
|
||||
54
|
||||
00:04:44,650 --> 00:04:50,000
|
||||
They all look correctly classified to me, except for the ones in Fanghuan's repository.
|
||||
|
||||
55
|
||||
00:04:50,000 --> 00:04:55,920
|
||||
I manually went through all of the ones where I didn't already know based on the filename or the repository owner.
|
||||
|
||||
56
|
||||
00:04:56,526 --> 00:05:00,000
|
||||
[Presses button] It now correctly classifies all of my test files.
|
||||
|
||||
57
|
||||
00:05:00,000 --> 00:05:05,970
|
||||
R. Pavlick, thanks for this. These changes will be live in the next release of Linguist. In the next couple of weeks.
|
||||
|
||||
58
|
||||
00:05:05,970 --> 00:05:07,450
|
||||
Great! Thanks.
|
||||
42
samples/Text/filenames/readme.1st
Normal file
42
samples/Text/filenames/readme.1st
Normal file
@@ -0,0 +1,42 @@
|
||||
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec tincidunt
|
||||
volutpat metus, non accumsan tortor convallis id. Headline un oreiller.
|
||||
Il est recommandé que la boîte en carton. Micro-ondes et sollicitudin bien.
|
||||
|
||||
---------------------------------------------
|
||||
Pellentesque sodales lectus ac lorem tempus, non placerat blandit de nisi.
|
||||
Phasellus Cursus, eros, et parfois, il est arcu diam mollis felis, ac tempor
|
||||
nisl elit quis felis. Morbi nca nisi vel ligula interdum pas l'auteur de, ni
|
||||
peur. Mécène voix améliorée. Besoin de tirer gratuitement. Suspendisse
|
||||
fermentum convallis metus non blandit. Ac turpis quis de molestie de Mécène.
|
||||
Gluten. Donec urna leo, aliquet quis urna et, congue est plein. Pellentesque
|
||||
ut pretium erat, rutrum neque tincidunt. Donec hendrerit massa sed sapien
|
||||
dapibus ultrices.
|
||||
|
||||
==============================================
|
||||
Et le porche des Mécène, le prix de la société n'a pas, lacinia justo.
|
||||
Pellentesque habitant morbi tristique senectus et Netus et Malesuada fames
|
||||
egestas ac turpis. Ut leo mi, feugiat sagittis un ac id Mauris, posuere
|
||||
lobortis neque. Non, il n'y avait pas de varius tincidunt pretium.
|
||||
|
||||
En effet, nca pur hendrerit pellentesque sapien enim sagittis ipsum, aliquam
|
||||
tempor est récolté dans le jeu. Ut sempre egestas ultrices lorem à risus.
|
||||
Même arcu dolor, ipsum, ma vie, il a été dit fringilla odio.
|
||||
|
||||
|
||||
- Lorem ipsum eu commodo imperdiet sem
|
||||
- ligula arcu placerat turpis, une
|
||||
- importante lorem nisi eget urna.
|
||||
|
||||
Curabitur aliquam accumsan nulla blandit mollis. Celtics à la succession!
|
||||
Id ou pas d'alcool. A iaculis Duis consectetur vitae enim. Et magnis dis
|
||||
parturiente montes Cras iaculis justo eu libero. Thermal non sapien quis
|
||||
nisi Pellentesque placerat. Praesent fringilla diam nisl, nca dignissim
|
||||
sem lobortis feugiat. Vivre beaucoup de pauvreté.
|
||||
|
||||
Morbi non justo eleifend!
|
||||
|
||||
Lacinia lacus fringilla, il fut un temps. Sed dans nunc à une chanson des
|
||||
Beatles ou pour décorer. Aeneas de basket-ball de diamètre. Fusce felis à
|
||||
partir, pas de pellentesque eget, le stress thermique pulvinar. Etiam
|
||||
porta odio sed nibh accumsan tristique. Mécène tincidunt quis justo eget
|
||||
porttitor. Jusqu'à ce que l'élément de temps ciblé.
|
||||
662
samples/Turing/simplegame.t
Normal file
662
samples/Turing/simplegame.t
Normal file
@@ -0,0 +1,662 @@
|
||||
%This is a comment
|
||||
var x : array 0 .. 100 of int
|
||||
var rangeX, rangeY, loopFor : int := 0
|
||||
setscreen ("graphics:696;400,nobuttonbar")
|
||||
setscreen ("nocursor")
|
||||
setscreen ("noecho")
|
||||
var colourP : string := "Yellow"
|
||||
var title : int := Font.New ("Algerian:60")
|
||||
var subtitle : int := Font.New ("Algerian:20")
|
||||
var xValue, yValue, font1, font2, instructionsTitle : int
|
||||
var scoreR, scoreY, button : int := 0
|
||||
var scoreRS, scoreYS, PreventFor : string
|
||||
var win : string := "N"
|
||||
var full, samePlayer : boolean := false
|
||||
font1 := Font.New ("Algerian:20")
|
||||
font2 := Font.New ("TimesNewRoman:15")
|
||||
instructionsTitle := Font.New ("Algerian:35")
|
||||
var shouldPlay : boolean := true
|
||||
forward proc game
|
||||
for i : 0 .. 100
|
||||
x (i) := 0
|
||||
end for
|
||||
proc pauseProgram
|
||||
var reply : string (1)
|
||||
getch (reply)
|
||||
end pauseProgram
|
||||
process backgroundMusic
|
||||
loop
|
||||
exit when shouldPlay = false
|
||||
Music.PlayFile ("music.MP3")
|
||||
end loop
|
||||
end backgroundMusic
|
||||
proc winner
|
||||
cls
|
||||
win := "N"
|
||||
for i : 1 .. 100
|
||||
x (i) := 0
|
||||
end for
|
||||
drawfillbox (0, 0, 696, 400, black)
|
||||
scoreRS := "Red Wins: " + intstr (scoreR)
|
||||
scoreYS := "Yellow Wins: " + intstr (scoreY)
|
||||
Font.Draw ("", 190, 320, title, 48)
|
||||
Font.Draw (scoreRS, 0, 250, font1, 52)
|
||||
Font.Draw (scoreYS, 0, 220, font1, 52)
|
||||
Font.Draw ("Press any Key to continue.", 180, 100, subtitle, 12)
|
||||
pauseProgram
|
||||
game
|
||||
end winner
|
||||
body proc game
|
||||
for i : 1 .. 100
|
||||
x (i) := 0
|
||||
end for
|
||||
cls
|
||||
drawfillbox (0, 0, 700, 400, black)%Grid
|
||||
Draw.ThickLine (0, 400, 0, 0, 5, 48)
|
||||
Draw.ThickLine (696, 400, 696, 0, 5, 48)
|
||||
Draw.ThickLine (3, 0, 696, 0, 5, 48)
|
||||
Draw.ThickLine (696, 0, 696, 70, 5, 48)
|
||||
Draw.ThickLine (610, 70, 87, 70, 5, 48)
|
||||
Draw.ThickLine (87, 70, 87, 400, 5, 48)
|
||||
Draw.ThickLine (87, 400, 0, 400, 5, 48)
|
||||
Draw.ThickLine (173, 70, 173, 400, 5, 48)
|
||||
Draw.ThickLine (260, 70, 260, 400, 5, 48)
|
||||
Draw.ThickLine (347, 70, 347, 400, 5, 48)
|
||||
Draw.ThickLine (435, 70, 435, 400, 5, 48)
|
||||
Draw.ThickLine (521, 70, 521, 400, 5, 48)
|
||||
Draw.ThickLine (609, 70, 609, 400, 5, 48)
|
||||
Draw.ThickLine (0, 70, 87, 70, 2, 11) %NEW!
|
||||
Draw.ThickLine (0, 120, 87, 120, 2, 11)
|
||||
Draw.ThickLine (0, 170, 87, 170, 2, 11)
|
||||
Draw.ThickLine (0, 220, 87, 220, 2, 11)
|
||||
Draw.ThickLine (0, 270, 87, 270, 2, 11)
|
||||
Draw.ThickLine (0, 320, 87, 320, 2, 11)
|
||||
Draw.ThickLine (0, 370, 87, 370, 2, 11)
|
||||
Draw.ThickLine (609, 70, 696, 70, 2, 11) %Part 2
|
||||
Draw.ThickLine (609, 120, 696, 120, 2, 11)
|
||||
Draw.ThickLine (609, 170, 696, 170, 2, 11)
|
||||
Draw.ThickLine (609, 220, 696, 220, 2, 11)
|
||||
Draw.ThickLine (609, 270, 696, 270, 2, 11)
|
||||
Draw.ThickLine (609, 320, 696, 320, 2, 11)
|
||||
Draw.ThickLine (609, 370, 696, 370, 2, 11)
|
||||
loop
|
||||
if colourP = "Yellow" then
|
||||
if button = 1 then
|
||||
if (rangeX >= 87 and rangeX <= 173) then
|
||||
%Drop on right corner (now verifies height)
|
||||
if x (1) = 0 then
|
||||
x (1) := 1
|
||||
loopFor := 300
|
||||
elsif x (2) = 0 then
|
||||
x (2) := 1
|
||||
loopFor := 250
|
||||
elsif x (3) = 0 then
|
||||
x (3) := 1
|
||||
loopFor := 200
|
||||
elsif x (4) = 0 then
|
||||
x (4) := 1
|
||||
loopFor := 150
|
||||
elsif x (5) = 0 then
|
||||
x (5) := 1
|
||||
loopFor := 100
|
||||
elsif x (6) = 0 then
|
||||
x (6) := 1
|
||||
loopFor := 50
|
||||
else
|
||||
full := true
|
||||
samePlayer := true
|
||||
end if
|
||||
if full = true then
|
||||
full := false
|
||||
else
|
||||
for i : 1 .. loopFor
|
||||
drawfilloval (135, 401 - i, 25, 25, black)
|
||||
drawfilloval (135, 400 - i, 25, 25, yellow)
|
||||
delay (1)
|
||||
end for
|
||||
end if
|
||||
elsif (rangeX >= 174 and rangeX <= 260) then
|
||||
if x (7) = 0 then %Drop on right corner (now verifies height)
|
||||
x (7) := 1
|
||||
loopFor := 300
|
||||
elsif x (8) = 0 then
|
||||
x (8) := 1
|
||||
loopFor := 250
|
||||
elsif x (9) = 0 then
|
||||
x (9) := 1
|
||||
loopFor := 200
|
||||
elsif x (10) = 0 then
|
||||
x (10) := 1
|
||||
loopFor := 150
|
||||
elsif x (11) = 0 then
|
||||
x (11) := 1
|
||||
loopFor := 100
|
||||
elsif x (12) = 0 then
|
||||
x (12) := 1
|
||||
loopFor := 50
|
||||
else
|
||||
full := true
|
||||
samePlayer := true
|
||||
end if
|
||||
if full = true then
|
||||
full := false
|
||||
else
|
||||
for i : 1 .. loopFor
|
||||
drawfilloval (222, 401 - i, 25, 25, black)
|
||||
drawfilloval (222, 400 - i, 25, 25, yellow)
|
||||
delay (1)
|
||||
end for
|
||||
end if
|
||||
elsif (rangeX >= 261 and rangeX <= 347) then
|
||||
if x (13) = 0 then%Drop on right corner (now verifies height)
|
||||
x (13) := 1
|
||||
loopFor := 300
|
||||
elsif x (14) = 0 then
|
||||
x (14) := 1
|
||||
loopFor := 250
|
||||
elsif x (15) = 0 then
|
||||
x (15) := 1
|
||||
loopFor := 200
|
||||
elsif x (16) = 0 then
|
||||
x (16) := 1
|
||||
loopFor := 150
|
||||
elsif x (17) = 0 then
|
||||
x (17) := 1
|
||||
loopFor := 100
|
||||
elsif x (18) = 0 then
|
||||
x (18) := 1
|
||||
loopFor := 50
|
||||
else
|
||||
full := true
|
||||
end if
|
||||
if full = true then
|
||||
full := false
|
||||
samePlayer := true
|
||||
else
|
||||
for i : 1 .. loopFor
|
||||
drawfilloval (309, 401 - i, 25, 25, black)
|
||||
drawfilloval (309, 400 - i, 25, 25, yellow)
|
||||
delay (1)
|
||||
end for
|
||||
end if
|
||||
elsif (rangeX >= 348 and rangeX <= 434) then
|
||||
if x (19) = 0 then %Drop on right corner (now verifies height)
|
||||
x (19) := 1
|
||||
loopFor := 300
|
||||
elsif x (20) = 0 then
|
||||
x (20) := 1
|
||||
loopFor := 250
|
||||
elsif x (21) = 0 then
|
||||
x (21) := 1
|
||||
loopFor := 200
|
||||
elsif x (22) = 0 then
|
||||
x (22) := 1
|
||||
loopFor := 150
|
||||
elsif x (23) = 0 then
|
||||
x (23) := 1
|
||||
loopFor := 100
|
||||
elsif x (24) = 0 then
|
||||
x (24) := 1
|
||||
loopFor := 50
|
||||
else
|
||||
full := true
|
||||
samePlayer := true
|
||||
end if
|
||||
if full = true then
|
||||
full := false
|
||||
else
|
||||
for i : 1 .. loopFor
|
||||
drawfilloval (396, 401 - i, 25, 25, black)
|
||||
drawfilloval (396, 400 - i, 25, 25, yellow)
|
||||
delay (1)
|
||||
end for
|
||||
end if
|
||||
elsif (rangeX >= 435 and rangeX <= 521) then
|
||||
if x (25) = 0 then %Drop on right corner (now verifies height)
|
||||
x (25) := 1
|
||||
loopFor := 300
|
||||
elsif x (26) = 0 then
|
||||
x (26) := 1
|
||||
loopFor := 250
|
||||
elsif x (27) = 0 then
|
||||
x (27) := 1
|
||||
loopFor := 200
|
||||
elsif x (28) = 0 then
|
||||
x (28) := 1
|
||||
loopFor := 150
|
||||
elsif x (29) = 0 then
|
||||
x (29) := 1
|
||||
loopFor := 100
|
||||
elsif x (30) = 0 then
|
||||
x (30) := 1
|
||||
loopFor := 50
|
||||
else
|
||||
full := true
|
||||
samePlayer := true
|
||||
end if
|
||||
if full = true then
|
||||
full := false
|
||||
else
|
||||
for i : 1 .. loopFor
|
||||
drawfilloval (483, 401 - i, 25, 25, black)
|
||||
drawfilloval (483, 400 - i, 25, 25, yellow)
|
||||
delay (1)
|
||||
end for
|
||||
end if
|
||||
elsif (rangeX >= 522 and rangeX <= 609) then
|
||||
if x (31) = 0 then %Drop on right corner (now verifies height)
|
||||
x (31) := 1
|
||||
loopFor := 300
|
||||
elsif x (32) = 0 then
|
||||
x (32) := 1
|
||||
loopFor := 250
|
||||
elsif x (33) = 0 then
|
||||
x (33) := 1
|
||||
loopFor := 200
|
||||
elsif x (34) = 0 then
|
||||
x (34) := 1
|
||||
loopFor := 150
|
||||
elsif x (35) = 0 then
|
||||
x (35) := 1
|
||||
loopFor := 100
|
||||
elsif x (36) = 0 then
|
||||
x (36) := 1
|
||||
loopFor := 50
|
||||
else
|
||||
full := true
|
||||
samePlayer := true
|
||||
end if
|
||||
if full = true then
|
||||
full := false
|
||||
else
|
||||
for i : 1 .. loopFor
|
||||
drawfilloval (570, 401 - i, 25, 25, black)
|
||||
drawfilloval (570, 400 - i, 25, 25, yellow)
|
||||
delay (1)
|
||||
end for
|
||||
end if
|
||||
end if
|
||||
if samePlayer = true then
|
||||
samePlayer := false
|
||||
else
|
||||
colourP := "Red"
|
||||
end if
|
||||
end if
|
||||
else
|
||||
if button = 1 then
|
||||
if (rangeX >= 87 and rangeX <= 173) then
|
||||
if x (1) = 0 then %Drop on right corner (now verifies height)
|
||||
x (1) := 2
|
||||
loopFor := 300
|
||||
elsif x (2) = 0 then
|
||||
x (2) := 2
|
||||
loopFor := 250
|
||||
elsif x (3) = 0 then
|
||||
x (3) := 2
|
||||
loopFor := 200
|
||||
elsif x (4) = 0 then
|
||||
x (4) := 2
|
||||
loopFor := 150
|
||||
elsif x (5) = 0 then
|
||||
x (5) := 2
|
||||
loopFor := 100
|
||||
elsif x (6) = 0 then
|
||||
x (6) := 2
|
||||
loopFor := 50
|
||||
else
|
||||
full := true
|
||||
samePlayer := true
|
||||
end if
|
||||
if full = true then
|
||||
full := false
|
||||
else
|
||||
for i : 1 .. loopFor
|
||||
drawfilloval (135, 401 - i, 25, 25, black)
|
||||
drawfilloval (135, 400 - i, 25, 25, 12)
|
||||
delay (1)
|
||||
end for
|
||||
end if
|
||||
elsif (rangeX >= 174 and rangeX <= 260) then
|
||||
if x (7) = 0 then %Drop on right corner (now verifies height)
|
||||
x (7) := 2
|
||||
loopFor := 300
|
||||
elsif x (8) = 0 then
|
||||
x (8) := 2
|
||||
loopFor := 250
|
||||
elsif x (9) = 0 then
|
||||
x (9) := 2
|
||||
loopFor := 200
|
||||
elsif x (10) = 0 then
|
||||
x (10) := 2
|
||||
loopFor := 150
|
||||
elsif x (11) = 0 then
|
||||
x (11) := 2
|
||||
loopFor := 100
|
||||
elsif x (12) = 0 then
|
||||
x (12) := 2
|
||||
loopFor := 50
|
||||
else
|
||||
full := true
|
||||
samePlayer := true
|
||||
end if
|
||||
if full = true then
|
||||
full := false
|
||||
else
|
||||
for i : 1 .. loopFor
|
||||
drawfilloval (222, 401 - i, 25, 25, black)
|
||||
drawfilloval (222, 400 - i, 25, 25, 12)
|
||||
delay (1)
|
||||
end for
|
||||
end if
|
||||
elsif (rangeX >= 261 and rangeX <= 347) then
|
||||
if x (13) = 0 then %Drop on right corner (now verifies height)
|
||||
x (13) := 2
|
||||
loopFor := 300
|
||||
elsif x (14) = 0 then
|
||||
x (14) := 2
|
||||
loopFor := 250
|
||||
elsif x (15) = 0 then
|
||||
x (15) := 2
|
||||
loopFor := 200
|
||||
elsif x (16) = 0 then
|
||||
x (16) := 2
|
||||
loopFor := 150
|
||||
elsif x (17) = 0 then
|
||||
x (17) := 2
|
||||
loopFor := 100
|
||||
elsif x (18) = 0 then
|
||||
x (18) := 2
|
||||
loopFor := 50
|
||||
else
|
||||
full := true
|
||||
samePlayer := true
|
||||
end if
|
||||
if full = true then
|
||||
samePlayer := true
|
||||
else
|
||||
for i : 1 .. loopFor
|
||||
drawfilloval (309, 401 - i, 25, 25, black)
|
||||
drawfilloval (309, 400 - i, 25, 25, 12)
|
||||
delay (1)
|
||||
end for
|
||||
end if
|
||||
elsif (rangeX >= 348 and rangeX <= 434) then
|
||||
%Drop on right corner (now verifies height)
|
||||
if x (19) = 0 then
|
||||
x (19) := 2
|
||||
loopFor := 300
|
||||
elsif x (20) = 0 then
|
||||
x (20) := 2
|
||||
loopFor := 250
|
||||
elsif x (21) = 0 then
|
||||
x (21) := 2
|
||||
loopFor := 200
|
||||
elsif x (22) = 0 then
|
||||
x (22) := 2
|
||||
loopFor := 150
|
||||
elsif x (23) = 0 then
|
||||
x (23) := 2
|
||||
loopFor := 100
|
||||
elsif x (24) = 0 then
|
||||
x (24) := 2
|
||||
loopFor := 50
|
||||
else
|
||||
full := true
|
||||
samePlayer := true
|
||||
end if
|
||||
if full = true then
|
||||
full := false
|
||||
else
|
||||
for i : 1 .. loopFor
|
||||
drawfilloval (396, 401 - i, 25, 25, black)
|
||||
drawfilloval (396, 400 - i, 25, 25, 12)
|
||||
delay (1)
|
||||
end for
|
||||
end if
|
||||
elsif (rangeX >= 435 and rangeX <= 521) then
|
||||
%Drop on right corner (now verifies height)
|
||||
if x (25) = 0 then
|
||||
x (25) := 2
|
||||
loopFor := 300
|
||||
elsif x (26) = 0 then
|
||||
x (26) := 2
|
||||
loopFor := 250
|
||||
elsif x (27) = 0 then
|
||||
x (27) := 2
|
||||
loopFor := 200
|
||||
elsif x (28) = 0 then
|
||||
x (28) := 2
|
||||
loopFor := 150
|
||||
elsif x (29) = 0 then
|
||||
x (29) := 2
|
||||
loopFor := 100
|
||||
elsif x (30) = 0 then
|
||||
x (30) := 2
|
||||
loopFor := 50
|
||||
else
|
||||
full := true
|
||||
samePlayer := true
|
||||
end if
|
||||
if full = true then
|
||||
full := false
|
||||
else
|
||||
for i : 1 .. loopFor
|
||||
drawfilloval (483, 401 - i, 25, 25, black)
|
||||
drawfilloval (483, 400 - i, 25, 25, 12)
|
||||
delay (1)
|
||||
end for
|
||||
end if
|
||||
elsif (rangeX >= 522 and rangeX <= 609) then
|
||||
%Drop on right corner (now verifies height)
|
||||
if x (31) = 0 then
|
||||
x (31) := 2
|
||||
loopFor := 300
|
||||
elsif x (32) = 0 then
|
||||
x (32) := 2
|
||||
loopFor := 250
|
||||
elsif x (33) = 0 then
|
||||
x (33) := 2
|
||||
loopFor := 200
|
||||
elsif x (34) = 0 then
|
||||
x (34) := 2
|
||||
loopFor := 150
|
||||
elsif x (35) = 0 then
|
||||
x (35) := 2
|
||||
loopFor := 100
|
||||
elsif x (36) = 0 then
|
||||
x (36) := 2
|
||||
loopFor := 50
|
||||
else
|
||||
full := true
|
||||
samePlayer := true
|
||||
end if
|
||||
if full = true then
|
||||
full := false
|
||||
else
|
||||
for i : 1 .. loopFor
|
||||
drawfilloval (570, 401 - i, 25, 25, black)
|
||||
drawfilloval (570, 400 - i, 25, 25, 12)
|
||||
delay (1)
|
||||
end for
|
||||
end if
|
||||
end if
|
||||
if samePlayer then
|
||||
samePlayer := false
|
||||
else
|
||||
colourP := "Yellow"
|
||||
end if
|
||||
|
||||
end if
|
||||
end if
|
||||
mousewhere (rangeX, rangeY, button)
|
||||
%Detect Winner - Horizontal Verification
|
||||
for i : 1 .. 18
|
||||
if (x (i) = x (i + 6) and x (i) = x (i + 12) and x (i) = x (i + 18) and x (i) = 1) then
|
||||
scoreY := scoreY + 1
|
||||
win := "Y" %Red
|
||||
elsif x (i) = x (i + 6) and x (i) = x (i + 12) and x (i) = x (i + 18) and x (i) = 2 then
|
||||
scoreR := scoreR + 1
|
||||
win := "Y"
|
||||
if i > 6 then
|
||||
if x (i - 6) = x (i) and x (i) = x (i + 6) and x (i) = x (i + 12) and x (i) = 2 then
|
||||
scoreR := scoreR + 1 %Yellow
|
||||
win := "Y"
|
||||
elsif x (i - 6) = x (i) and x (i) = x (i + 6) and x (i) = x (i + 12) and x (i) = 1 then
|
||||
scoreY := scoreY + 1 %Yellow
|
||||
win := "Y"
|
||||
end if
|
||||
end if
|
||||
end if
|
||||
end for
|
||||
%Verticle Detection
|
||||
for i : 1 .. 36 by 6
|
||||
if (x (i) = x (i + 1) and x (i) = x (i + 2) and x (i) = x (i + 3) and x (i) = 1) then
|
||||
scoreY := scoreY + 1
|
||||
win := "Y"
|
||||
elsif (x (i) = x (i + 1) and x (i) = x (i + 2) and x (i) = x (i + 3) and x (i) = 2) then
|
||||
scoreR := scoreR + 1
|
||||
win := "Y"
|
||||
elsif (x (i + 1) = x (i + 2) and x (i + 1) = x (i + 3) and x (i + 1) = x (i + 4) and x (i + 1) = 1) then
|
||||
scoreY := scoreY + 1
|
||||
win := "Y"
|
||||
elsif (x (i + 1) = x (i + 2) and x (i + 1) = x (i + 3) and x (i + 1) = x (i + 4) and x (i + 1) = 2) then
|
||||
scoreR := scoreR + 1
|
||||
win := "Y"
|
||||
elsif (x (i + 2) = x (i + 3) and x (i + 2) = x (i + 4) and x (i + 2) = x (i + 5) and x (i + 2) = 1) then
|
||||
scoreY := scoreY + 1
|
||||
win := "Y"
|
||||
elsif (x (i + 2) = x (i + 3) and x (i + 2) = x (i + 4) and x (i + 2) = x (i + 5) and x (i + 2) = 2) then
|
||||
scoreR := scoreR + 1
|
||||
win := "Y"
|
||||
end if
|
||||
end for
|
||||
for i : 1 .. 36 %Positive Slope
|
||||
if (x (i) = x (i + 7) and x (i) = x (i + 14) and x (i) = x (i + 21) and x (i) = 1) then
|
||||
scoreY := scoreY + 1
|
||||
win := "Y"
|
||||
elsif (x (i) = x (i + 7) and x (i) = x (i + 14) and x (i) = x (i + 21) and x (i) = 2) then
|
||||
scoreR := scoreR + 1
|
||||
win := "Y"
|
||||
elsif (x (i + 1) = x (i + 8) and x (i + 1) = x (i + 15) and x (i + 1) = x (i + 22) and x (i + 1) = 2) then
|
||||
scoreR := scoreR + 1
|
||||
win := "Y"
|
||||
elsif (x (i + 1) = x (i + 8) and x (i + 1) = x (i + 15) and x (i + 1) = x (i + 22) and x (i + 1) = 1) then
|
||||
scoreY := scoreY + 1
|
||||
win := "Y"
|
||||
elsif (x (i + 2) = x (i + 9) and x (i + 2) = x (i + 16) and x (i + 2) = x (i + 23) and x (i + 2) = 1) then
|
||||
scoreY := scoreY + 1
|
||||
win := "Y"
|
||||
elsif (x (i + 2) = x (i + 9) and x (i + 2) = x (i + 16) and x (i + 2) = x (i + 23) and x (i + 2) = 2) then
|
||||
scoreR := scoreR + 1
|
||||
win := "Y"
|
||||
elsif (x (1) = x (7) and x (1) = x (13) and x (1) = x (19) and x (1) = 1) then
|
||||
scoreY := scoreY + 1
|
||||
win := "Y"
|
||||
elsif (x (1) = x (7) and x (1) = x (13) and x (1) = x (19) and x (1) = 2) then
|
||||
scoreR := scoreR + 1
|
||||
win := "Y"
|
||||
end if
|
||||
end for
|
||||
for i : 1 .. 70 %Negative Slope
|
||||
if i > 24 then
|
||||
if (x (i) = x (i - 5) and x (i) = x (i - 10) and x (i) = x (i - 15) and x (i) = 1) then
|
||||
scoreY := scoreY + 1
|
||||
win := "Y"
|
||||
elsif (x (i) = x (i - 5) and x (i) = x (i - 10) and x (i) = x (i - 15) and x (i) = 2) then
|
||||
scoreR := scoreR + 1
|
||||
win := "Y"
|
||||
elsif (x (i + 1) = x (i - 6) and x (i - 1) = x (i - 11) and x (i - 1) = x (i - 16) and x (i + 1) = 2) then
|
||||
scoreR := scoreR + 1
|
||||
win := "Y"
|
||||
elsif (x (i + 1) = x (i - 6) and x (i - 1) = x (i - 11) and x (i - 1) = x (i - 16) and x (i + 1) = 1) then
|
||||
scoreY := scoreY + 1
|
||||
win := "Y"
|
||||
elsif (x (i + 2) = x (i - 7) and x (i - 2) = x (i - 12) and x (i - 2) = x (i - 17) and x (i + 2) = 1) then
|
||||
scoreY := scoreY + 1
|
||||
win := "Y"
|
||||
elsif (x (i + 2) = x (i - 7) and x (i + 2) = x (i - 12) and x (i - 2) = x (i - 17) and x (i + 2) = 2) then
|
||||
scoreR := scoreR + 1
|
||||
win := "Y"
|
||||
end if
|
||||
end if
|
||||
end for
|
||||
exit when win = "Y"
|
||||
end loop
|
||||
winner
|
||||
end game
|
||||
proc mainMenu
|
||||
drawfillbox (0, 0, 696, 400, black)
|
||||
Font.Draw ("", 295, 220, font1, 48)
|
||||
Font.Draw ("", 251, 150, font1, 48)
|
||||
Font.Draw ("", 305, 79, font1, 48)
|
||||
loop
|
||||
Font.Draw ("Connect4", 155, 290, title, 52)
|
||||
Mouse.Where (xValue, yValue, button)
|
||||
if xValue >= 215 and xValue <= 455 then
|
||||
if yValue >= 200 and yValue <= 250 then
|
||||
if button = 1 then
|
||||
delay (1000)
|
||||
game
|
||||
exit
|
||||
end if
|
||||
drawbox (215, 200, 455, 250, 48)
|
||||
else
|
||||
drawbox (215, 200, 455, 250, black)
|
||||
end if
|
||||
if yValue >= 130 and yValue <= 180 then
|
||||
if button = 1 then
|
||||
drawfillbox (0, 0, 696, 400, black)
|
||||
Font.Draw ("", 70, 350, instructionsTitle, 48)
|
||||
Font.Draw ("", 0, 320, font2, 52)
|
||||
Font.Draw ("", 0, 280, font2, 52)
|
||||
Font.Draw ("", 0, 240, font2, 52)
|
||||
Font.Draw ("", 0, 200, font2, 52)
|
||||
Font.Draw ("", 245, 75, font2, 14)
|
||||
pauseProgram
|
||||
mainMenu
|
||||
end if
|
||||
drawbox (215, 130, 455, 180, 48)
|
||||
else
|
||||
drawbox (215, 130, 455, 180, black)
|
||||
end if
|
||||
if yValue >= 60 and yValue <= 110 then
|
||||
if button = 1 then
|
||||
shouldPlay := false
|
||||
exit
|
||||
end if
|
||||
drawbox (215, 60, 455, 110, 48)
|
||||
else
|
||||
drawbox (215, 60, 455, 110, black)
|
||||
end if
|
||||
end if
|
||||
exit when button = 1
|
||||
end loop
|
||||
end mainMenu
|
||||
proc intro
|
||||
drawfillbox (0, 0, 696, 400, black)
|
||||
for i : 1 .. 400
|
||||
drawfillbox (0, 0, 696, 400, black)
|
||||
Font.Draw ("", 560 - i, 250, title, 48)
|
||||
Font.Draw ("", -255 + i, 220, subtitle, 52)
|
||||
delay (4)
|
||||
end for
|
||||
for i : 1 .. 390
|
||||
drawfilloval (40, 401 - i, 20, 20, black)
|
||||
drawfilloval (656, 401 - i, 20, 20, black)
|
||||
drawfilloval (656, 400 - i, 20, 20, 12)
|
||||
drawfilloval (40, 400 - i, 20, 20, yellow)
|
||||
delay (3)
|
||||
end for
|
||||
loop
|
||||
drawfillbox (0, 0, 696, 100, black)
|
||||
Font.Draw ("Press any Key to Continue.", 169, 20, subtitle, 12)
|
||||
delay (300)
|
||||
drawfillbox (0, 0, 696, 100, black)
|
||||
Font.Draw ("Press any Key to Continue.", 169, 20, subtitle, 14)
|
||||
delay (300)
|
||||
exit when hasch
|
||||
end loop
|
||||
mainMenu
|
||||
end intro
|
||||
%fork backgroundMusic
|
||||
intro
|
||||
@@ -1,19 +1,19 @@
|
||||
% Accepts a number and calculates its factorial
|
||||
|
||||
function factorial (n: int) : real
|
||||
if n = 0 then
|
||||
result 1
|
||||
else
|
||||
result n * factorial (n - 1)
|
||||
if n = 0 then
|
||||
result 1
|
||||
else
|
||||
result n * factorial (n - 1)
|
||||
end if
|
||||
end factorial
|
||||
|
||||
var n: int
|
||||
loop
|
||||
put "Please input an integer: " ..
|
||||
get n
|
||||
exit when n >= 0
|
||||
put "Input must be a non-negative integer."
|
||||
put "Please input an integer: " ..
|
||||
get n
|
||||
exit when n >= 0
|
||||
put "Input must be a non-negative integer."
|
||||
end loop
|
||||
|
||||
put "The factorial of ", n, " is ", factorial (n)
|
||||
put "The factorial of ", n, " is ", factorial (n)
|
||||
18
samples/Wavefront Material/dice.mtl
Executable file
18
samples/Wavefront Material/dice.mtl
Executable file
@@ -0,0 +1,18 @@
|
||||
# 3ds Max Wavefront OBJ Exporter v0.97b - (c)2007 guruware
|
||||
# File Created: 27.05.2016 18:10:49
|
||||
|
||||
newmtl Dice
|
||||
Ns 9.99999905
|
||||
Ni 1.50000000
|
||||
d 1.00000000
|
||||
Tr 0.00000000
|
||||
Tf 1.00000000 1.00000000 1.00000000
|
||||
illum 2
|
||||
Ka 0.58823532 0.58823532 0.58823532
|
||||
Kd 0.58823532 0.58823532 0.58823532
|
||||
Ks 0.44999999 0.44999999 0.44999999
|
||||
Ke 0.00000000 0.00000000 0.00000000
|
||||
map_Ka C:\Users\johng\Desktop\dice.png
|
||||
map_Kd C:\Users\johng\Desktop\dice.png
|
||||
map_bump C:\Users\johng\Desktop\dice.png
|
||||
bump C:\Users\johng\Desktop\dice.png
|
||||
12
samples/Wavefront Material/ripple.mtl
Executable file
12
samples/Wavefront Material/ripple.mtl
Executable file
@@ -0,0 +1,12 @@
|
||||
# 3ds Max Wavefront OBJ Exporter v0.97b - (c)2007 guruware
|
||||
# File Created: 27.05.2016 16:25:06
|
||||
|
||||
newmtl wire_061135006
|
||||
Ns 32
|
||||
d 1
|
||||
Tr 0
|
||||
Tf 1 1 1
|
||||
illum 2
|
||||
Ka 0.23921570 0.52941179 0.02352941
|
||||
Kd 0.23921570 0.52941179 0.02352941
|
||||
Ks 0.34999999 0.34999999 0.34999999
|
||||
38
samples/Wavefront Material/shapes.mtl
Executable file
38
samples/Wavefront Material/shapes.mtl
Executable file
@@ -0,0 +1,38 @@
|
||||
# 3ds Max Wavefront OBJ Exporter v0.97b - (c)2007 guruware
|
||||
# File Created: 27.05.2016 16:20:17
|
||||
|
||||
newmtl Material__41
|
||||
Ns 10.00000000
|
||||
Ni 1.50000000
|
||||
d 1.00000000
|
||||
Tr 0.00000000
|
||||
Tf 1.00000000 1.00000000 1.00000000
|
||||
illum 2
|
||||
Ka 0.58800000 0.58800000 0.58800000
|
||||
Kd 1.00000000 0.00000000 0.00000000
|
||||
Ks 0.00000000 0.00000000 0.00000000
|
||||
Ke 0.00000000 0.00000000 0.00000000
|
||||
|
||||
newmtl Material__42
|
||||
Ns 10.00000000
|
||||
Ni 1.50000000
|
||||
d 1.00000000
|
||||
Tr 0.00000000
|
||||
Tf 1.00000000 1.00000000 1.00000000
|
||||
illum 2
|
||||
Ka 0.00000000 0.00000000 1.00000000
|
||||
Kd 0.00000000 0.00000000 1.00000000
|
||||
Ks 0.00000000 0.00000000 0.00000000
|
||||
Ke 0.00000000 0.00000000 0.00000000
|
||||
|
||||
newmtl Material__43
|
||||
Ns 10.00000000
|
||||
Ni 1.50000000
|
||||
d 1.00000000
|
||||
Tr 0.00000000
|
||||
Tf 1.00000000 1.00000000 1.00000000
|
||||
illum 2
|
||||
Ka 0.35294119 0.35294119 0.35294119
|
||||
Kd 0.50196081 0.50588238 0.23529413
|
||||
Ks 0.00000000 0.00000000 0.00000000
|
||||
Ke 0.00000000 0.00000000 0.00000000
|
||||
12
samples/Wavefront Material/spline.mtl
Executable file
12
samples/Wavefront Material/spline.mtl
Executable file
@@ -0,0 +1,12 @@
|
||||
# 3ds Max Wavefront OBJ Exporter v0.97b - (c)2007 guruware
|
||||
# File Created: 27.05.2016 16:27:25
|
||||
|
||||
newmtl wire_088177027
|
||||
Ns 32
|
||||
d 1
|
||||
Tr 0
|
||||
Tf 1 1 1
|
||||
illum 2
|
||||
Ka 0.34509805 0.69411767 0.10588236
|
||||
Kd 0.34509805 0.69411767 0.10588236
|
||||
Ks 0.34999999 0.34999999 0.34999999
|
||||
68
samples/Wavefront Object/dice.obj
Executable file
68
samples/Wavefront Object/dice.obj
Executable file
@@ -0,0 +1,68 @@
|
||||
# 3ds Max Wavefront OBJ Exporter v0.97b - (c)2007 guruware
|
||||
# File Created: 27.05.2016 18:10:49
|
||||
|
||||
mtllib dice.mtl
|
||||
|
||||
#
|
||||
# object Dice
|
||||
#
|
||||
|
||||
v -30.00000000 0.00000000 30.00000000
|
||||
v -30.00000000 0.00000000 -30.00000000
|
||||
v 30.00000000 0.00000000 -30.00000000
|
||||
v 30.00000000 0.00000000 30.00000000
|
||||
v -30.00000000 60.00000000 30.00000000
|
||||
v 30.00000000 60.00000000 30.00000000
|
||||
v 30.00000000 60.00000000 -30.00000000
|
||||
v -30.00000000 60.00000000 -30.00000000
|
||||
# 8 vertices
|
||||
|
||||
vn 0.00000000 -1.00000000 -0.00000000
|
||||
vn 0.00000000 1.00000000 -0.00000000
|
||||
vn 0.00000000 0.00000000 1.00000000
|
||||
vn 1.00000000 0.00000000 -0.00000000
|
||||
vn 0.00000000 0.00000000 -1.00000000
|
||||
vn -1.00000000 0.00000000 -0.00000000
|
||||
# 6 vertex normals
|
||||
|
||||
vt 1.00183499 -0.01224804 60.49999619
|
||||
vt 1.00183487 0.48775199 60.49999619
|
||||
vt 0.66850162 0.48775196 60.50000381
|
||||
vt 0.66850162 -0.01224804 60.50000381
|
||||
vt -0.00046772 0.49891680 0.50000000
|
||||
vt 0.33286563 0.49891669 0.50000000
|
||||
vt 0.33286572 0.99891669 0.50000000
|
||||
vt -0.00046766 0.99891680 0.50000000
|
||||
vt -0.00046772 0.00000006 0.62999344
|
||||
vt 0.33286560 0.00000003 0.63000107
|
||||
vt 0.33286566 0.50000000 0.62999916
|
||||
vt -0.00046772 0.50000012 0.62999153
|
||||
vt 0.66447806 0.49891663 -29.58417892
|
||||
vt 0.66447806 0.99891663 -29.58417130
|
||||
vt 0.33114472 0.99891663 -29.58417320
|
||||
vt 0.33114466 0.49891669 -29.58418083
|
||||
vt 0.99669039 1.00000000 60.36999512
|
||||
vt 0.66335702 1.00000000 60.37000275
|
||||
vt 0.66335702 0.50000000 60.36999893
|
||||
vt 0.99669039 0.49999994 60.36999130
|
||||
vt 0.33280861 0.00000006 90.58419037
|
||||
vt 0.66614199 0.00000006 90.58418274
|
||||
vt 0.66614199 0.50000000 90.58417511
|
||||
vt 0.33280861 0.50000000 90.58419037
|
||||
# 24 texture coords
|
||||
|
||||
g Dice
|
||||
usemtl Dice
|
||||
s 2
|
||||
f 1/1/1 2/2/1 3/3/1 4/4/1
|
||||
s 4
|
||||
f 5/5/2 6/6/2 7/7/2 8/8/2
|
||||
s 8
|
||||
f 1/9/3 4/10/3 6/11/3 5/12/3
|
||||
s 16
|
||||
f 4/13/4 3/14/4 7/15/4 6/16/4
|
||||
s 32
|
||||
f 3/17/5 2/18/5 8/19/5 7/20/5
|
||||
s 64
|
||||
f 2/21/6 1/22/6 5/23/6 8/24/6
|
||||
# 6 polygons
|
||||
63
samples/Wavefront Object/random.obj
Normal file
63
samples/Wavefront Object/random.obj
Normal file
@@ -0,0 +1,63 @@
|
||||
cstype bmatrix
|
||||
deg 3 3
|
||||
step 3 3
|
||||
bmat u 1 -3 3 -1 \
|
||||
0 3 -6 3 \
|
||||
0 0 3 -3 \
|
||||
0 0 0 1
|
||||
|
||||
bmat v 1 -3 -3 2 \
|
||||
2 2 2 3 \
|
||||
0 0 0 -2 \
|
||||
0 0 0 2
|
||||
|
||||
# Special point and space curve data
|
||||
vp 0.500
|
||||
vp 0.700
|
||||
vp 1.100
|
||||
vp 0.200 0.950
|
||||
v 0.300 1.500 0.100
|
||||
v 0.000 0.000 0.000
|
||||
v 1.000 1.000 0.000
|
||||
v 2.000 1.000 0.000
|
||||
v 3.000 0.000 0.000
|
||||
cstype bezier
|
||||
deg 3
|
||||
curv 0.2 0.9 -4 -3 -2 -1
|
||||
sp 1
|
||||
parm u 0.00 1.00
|
||||
end
|
||||
# Trimming curve
|
||||
vp -0.675 1.850 3.000
|
||||
vp 0.915 1.930
|
||||
vp 2.485 0.470 2.000
|
||||
vp 2.485 -1.030
|
||||
vp 1.605 -1.890 10.700
|
||||
vp -0.745 -0.654 0.500
|
||||
cstype rat bezier
|
||||
curv2 -6 -5 -4 -3 -2 -1 -6
|
||||
parm u 0.00 1.00 2.00
|
||||
sp 2 3
|
||||
end
|
||||
|
||||
# Surface
|
||||
v -1.350 -1.030 0.000
|
||||
v 0.130 -1.030 0.432 7.600
|
||||
v 1.480 -1.030 0.000 2.300
|
||||
v -1.460 0.060 0.201
|
||||
v 0.120 0.060 0.915 0.500
|
||||
v 1.380 0.060 0.454 1.500
|
||||
v -1.480 1.030 0.000 2.300
|
||||
v 0.120 1.030 0.394 6.100
|
||||
v 1.170 1.030 0.000 3.300
|
||||
|
||||
cstype rat bspline
|
||||
deg 2 2
|
||||
surf -1.0 2.5 -2.0 2.0 -9 -8 -7 -6 -5 -4 -3 -2 -1
|
||||
parm u -1.00 -1.00 -1.00 2.50 2.50 2.50
|
||||
parm v -2.00 -2.00 -2.00 2.00 2.00 2.00
|
||||
trim 0.0 2.0 1 2.2 2.2 3
|
||||
sp 4
|
||||
|
||||
con 1 2.0 2.0 1 2 4.0 3.0 1
|
||||
end
|
||||
211
samples/Wavefront Object/ripple.obj
Executable file
211
samples/Wavefront Object/ripple.obj
Executable file
@@ -0,0 +1,211 @@
|
||||
# 3ds Max Wavefront OBJ Exporter v0.97b - (c)2007 guruware
|
||||
# File Created: 27.05.2016 16:25:06
|
||||
|
||||
mtllib ripple.mtl
|
||||
|
||||
#
|
||||
# object Plane001
|
||||
#
|
||||
|
||||
v -50.94465637 46.62910461 25.64281845
|
||||
v -37.48844147 24.20991898 16.95789337
|
||||
v -50.94465637 41.79552460 16.95789337
|
||||
v -37.48844147 27.38044548 25.64281845
|
||||
v -37.48844147 20.64456940 8.27297115
|
||||
v -50.94465637 36.20748138 8.27297115
|
||||
v -24.03222656 14.00123024 8.27297115
|
||||
v -24.03222656 17.55510902 25.64281845
|
||||
v -37.48844147 16.93638992 -0.41195297
|
||||
v -50.94465637 30.29615402 -0.41195297
|
||||
v -37.48844147 13.33736229 -9.09687710
|
||||
v -50.94465637 24.49272728 -9.09687710
|
||||
v -24.03222656 12.37120342 -0.41195297
|
||||
v -24.03222656 10.91310787 -9.09687710
|
||||
v -10.57601166 13.59048653 8.27297115
|
||||
v -10.57601166 14.55468178 25.64281845
|
||||
v 2.88020325 16.72536278 8.27297115
|
||||
v 2.88020325 15.78074646 25.64281845
|
||||
v -10.57601166 13.76694107 -0.41195297
|
||||
v -10.57601166 14.20676041 -9.09687710
|
||||
v 2.88020325 20.20512009 -9.09687710
|
||||
v -37.48844147 10.09947586 -17.78180122
|
||||
v -50.94465637 19.22837830 -17.78180122
|
||||
v -37.48844147 7.47471571 -26.46672440
|
||||
v -50.94465637 14.93428612 -26.46672440
|
||||
v -24.03222656 9.68243504 -17.78180122
|
||||
v -24.03222656 8.73467827 -26.46672440
|
||||
v -50.94465637 12.04163361 -35.15164948
|
||||
v -37.48844147 5.07252359 -43.83657455
|
||||
v -50.94465637 10.98159790 -43.83657455
|
||||
v -24.03222656 7.90988255 -43.83657455
|
||||
v -10.57601166 14.77819061 -17.78180122
|
||||
v -10.57601166 15.34947777 -26.46672440
|
||||
v 2.88020325 23.95441628 -26.46672440
|
||||
v -10.57601166 15.96461296 -43.83657455
|
||||
v 2.88020325 25.70764923 -43.83657455
|
||||
v 16.33641815 20.71888542 8.27297115
|
||||
v 16.33641815 18.63488770 25.64281845
|
||||
v 29.79263306 22.88408279 8.27297115
|
||||
v 29.79263306 20.51868629 25.64281845
|
||||
v 16.33641815 25.89498520 -9.09687710
|
||||
v 29.79263306 28.26315308 -9.09687710
|
||||
v 43.24884796 20.53397751 8.27297115
|
||||
v 43.24884796 18.83372879 25.64281845
|
||||
v 56.70506287 10.98159790 8.27297115
|
||||
v 56.70506287 10.98159790 25.64281845
|
||||
v 43.24884796 24.29642487 -9.09687710
|
||||
v 56.70506287 10.98159790 -9.09687710
|
||||
v 16.33641815 31.18479538 -26.46672440
|
||||
v 29.79263306 33.67591858 -26.46672440
|
||||
v 16.33641815 33.60993195 -43.83657455
|
||||
v 29.79263306 36.14238739 -43.83657455
|
||||
v 43.24884796 28.06308365 -26.46672440
|
||||
v 56.70506287 10.98159790 -26.46672440
|
||||
v 43.24884796 29.77596664 -43.83657455
|
||||
v 56.70506287 10.98159790 -43.83657455
|
||||
# 56 vertices
|
||||
|
||||
vn 0.76763725 0.57240576 -0.28824410
|
||||
vn 0.65690964 0.70898795 -0.25652644
|
||||
vn 0.74131417 0.58485949 -0.32923040
|
||||
vn 0.71128774 0.66027904 -0.24104214
|
||||
vn 0.57668960 0.75674146 -0.30784976
|
||||
vn 0.68667018 0.61596304 -0.38610050
|
||||
vn 0.23177305 0.95558769 -0.18202589
|
||||
vn 0.35748628 0.91861695 -0.16836406
|
||||
vn 0.49003005 0.80710864 -0.32931164
|
||||
vn 0.62462389 0.65700555 -0.42212400
|
||||
vn 0.39033067 0.86003071 -0.32861704
|
||||
vn 0.55869663 0.70821345 -0.43161529
|
||||
vn 0.10668588 0.97925276 -0.17228496
|
||||
vn -0.02931032 0.98739797 -0.15551880
|
||||
vn -0.07901792 0.99610978 -0.03900582
|
||||
vn 0.03497402 0.99911118 -0.02352911
|
||||
vn -0.26840743 0.95793903 0.10153976
|
||||
vn -0.16543458 0.98361683 0.07161918
|
||||
vn -0.19281031 0.98029876 0.04287769
|
||||
vn -0.30288765 0.95234644 0.03599080
|
||||
vn -0.40211844 0.89890224 0.17399880
|
||||
vn 0.28773862 0.90962982 -0.29963326
|
||||
vn 0.49455851 0.76858509 -0.40581867
|
||||
vn 0.17960025 0.95868921 -0.22058737
|
||||
vn 0.45494452 0.82066798 -0.34573048
|
||||
vn -0.15761316 0.97898537 -0.12940517
|
||||
vn -0.26093873 0.96179539 -0.08282847
|
||||
vn 0.42190838 0.88920695 -0.17693035
|
||||
vn 0.09655062 0.98630100 -0.13374706
|
||||
vn 0.39958632 0.90994275 -0.11106271
|
||||
vn -0.33997789 0.93774927 -0.07100248
|
||||
vn -0.39676505 0.91563439 0.06473898
|
||||
vn -0.48332906 0.87461358 0.03800077
|
||||
vn -0.49581528 0.85854882 0.13061842
|
||||
vn -0.53545648 0.84449571 0.01064764
|
||||
vn -0.53323698 0.84293228 0.07157855
|
||||
vn -0.21215707 0.95821202 0.19188292
|
||||
vn -0.17650788 0.97674274 0.12173164
|
||||
vn 0.02109022 0.97897238 0.20289963
|
||||
vn 0.00300862 0.99226630 0.12409085
|
||||
vn -0.26396522 0.92647272 0.26827350
|
||||
vn 0.06819490 0.95697868 0.28203061
|
||||
vn 0.40214399 0.90704513 0.12469723
|
||||
vn 0.34466815 0.93620455 0.06873771
|
||||
vn 0.56171304 0.82705635 0.02136020
|
||||
vn 0.50399899 0.86370426 -0.00000000
|
||||
vn 0.50896263 0.84233069 0.17730212
|
||||
vn 0.67437875 0.73730576 0.03991853
|
||||
vn -0.31544915 0.92877936 0.19457826
|
||||
vn 0.10895393 0.97185022 0.20889288
|
||||
vn -0.33574972 0.93407321 0.12157062
|
||||
vn 0.12362437 0.98257226 0.13881217
|
||||
vn 0.59271014 0.79456633 0.13175353
|
||||
vn 0.76462281 0.64369327 0.03179539
|
||||
vn 0.62271041 0.77744496 0.08838002
|
||||
vn 0.79732174 0.60305154 0.02463558
|
||||
# 56 vertex normals
|
||||
|
||||
g Plane001
|
||||
usemtl wire_061135006
|
||||
s 1
|
||||
f 1//1 2//2 3//3
|
||||
f 1//1 4//4 2//2
|
||||
f 3//3 5//5 6//6
|
||||
f 3//3 2//2 5//5
|
||||
f 2//2 7//7 5//5
|
||||
f 2//2 8//8 7//7
|
||||
f 2//2 4//4 8//8
|
||||
f 6//6 9//9 10//10
|
||||
f 6//6 5//5 9//9
|
||||
f 10//10 11//11 12//12
|
||||
f 10//10 9//9 11//11
|
||||
f 5//5 13//13 9//9
|
||||
f 5//5 7//7 13//13
|
||||
f 9//9 14//14 11//11
|
||||
f 9//9 13//13 14//14
|
||||
f 8//8 15//15 7//7
|
||||
f 8//8 16//16 15//15
|
||||
f 16//16 17//17 15//15
|
||||
f 16//16 18//18 17//17
|
||||
f 7//7 19//19 13//13
|
||||
f 7//7 15//15 19//19
|
||||
f 13//13 20//20 14//14
|
||||
f 13//13 19//19 20//20
|
||||
f 19//19 21//21 20//20
|
||||
f 19//19 17//17 21//21
|
||||
f 19//19 15//15 17//17
|
||||
f 22//22 12//12 11//11
|
||||
f 23//23 12//12 22//22
|
||||
f 24//24 23//23 22//22
|
||||
f 25//25 23//23 24//24
|
||||
f 11//11 26//26 22//22
|
||||
f 11//11 14//14 26//26
|
||||
f 22//22 27//27 24//24
|
||||
f 22//22 26//26 27//27
|
||||
f 28//28 29//29 30//30
|
||||
f 28//28 24//24 29//29
|
||||
f 28//28 25//25 24//24
|
||||
f 24//24 31//31 29//29
|
||||
f 24//24 27//27 31//31
|
||||
f 14//14 32//32 26//26
|
||||
f 14//14 20//20 32//32
|
||||
f 26//26 33//33 27//27
|
||||
f 26//26 32//32 33//33
|
||||
f 32//32 34//34 33//33
|
||||
f 32//32 21//21 34//34
|
||||
f 32//32 20//20 21//21
|
||||
f 27//27 35//35 31//31
|
||||
f 27//27 33//33 35//35
|
||||
f 33//33 36//36 35//35
|
||||
f 33//33 34//34 36//36
|
||||
f 18//18 37//37 17//17
|
||||
f 18//18 38//38 37//37
|
||||
f 38//38 39//39 37//37
|
||||
f 38//38 40//40 39//39
|
||||
f 17//17 41//41 21//21
|
||||
f 17//17 37//37 41//41
|
||||
f 37//37 42//42 41//41
|
||||
f 37//37 39//39 42//42
|
||||
f 40//40 43//43 39//39
|
||||
f 40//40 44//44 43//43
|
||||
f 44//44 45//45 43//43
|
||||
f 44//44 46//46 45//45
|
||||
f 39//39 47//47 42//42
|
||||
f 39//39 43//43 47//47
|
||||
f 43//43 48//48 47//47
|
||||
f 43//43 45//45 48//48
|
||||
f 21//21 49//49 34//34
|
||||
f 21//21 41//41 49//49
|
||||
f 41//41 50//50 49//49
|
||||
f 41//41 42//42 50//50
|
||||
f 34//34 51//51 36//36
|
||||
f 34//34 49//49 51//51
|
||||
f 49//49 52//52 51//51
|
||||
f 49//49 50//50 52//52
|
||||
f 42//42 53//53 50//50
|
||||
f 42//42 47//47 53//53
|
||||
f 47//47 54//54 53//53
|
||||
f 47//47 48//48 54//54
|
||||
f 50//50 55//55 52//52
|
||||
f 50//50 53//53 55//55
|
||||
f 53//53 56//56 55//55
|
||||
f 53//53 54//54 56//56
|
||||
# 0 polygons - 82 triangles
|
||||
1434
samples/Wavefront Object/shapes.obj
Executable file
1434
samples/Wavefront Object/shapes.obj
Executable file
File diff suppressed because it is too large
Load Diff
50
samples/Wavefront Object/spline.obj
Executable file
50
samples/Wavefront Object/spline.obj
Executable file
@@ -0,0 +1,50 @@
|
||||
# 3ds Max Wavefront OBJ Exporter v0.97b - (c)2007 guruware
|
||||
# File Created: 27.05.2016 16:27:25
|
||||
|
||||
mtllib spline.mtl
|
||||
|
||||
#
|
||||
# shape Line001
|
||||
#
|
||||
|
||||
v 71.96043396 50.40676880 7.76218033
|
||||
v 68.00450134 49.56087112 9.62696075
|
||||
v 58.35432816 47.37934113 12.77519226
|
||||
v 45.49077225 44.39643097 15.20822144
|
||||
v 31.89469528 41.14640045 14.92743301
|
||||
v 20.04695511 38.16349030 9.93418884
|
||||
v 12.42840576 35.98196030 -1.77015114
|
||||
v 11.51990128 35.13606262 -22.18419647
|
||||
v 11.96961975 32.52806473 -45.35875702
|
||||
v 7.61955643 26.33384705 -63.90428543
|
||||
v -0.25867081 18.99807358 -77.65885162
|
||||
v -10.39344025 12.96540833 -86.46051788
|
||||
v -21.51314926 10.68051147 -90.14735413
|
||||
v -32.34618759 14.58804321 -88.55743408
|
||||
v -41.62093735 27.13267326 -81.52883148
|
||||
v -45.51561356 42.52115250 -66.96699524
|
||||
v -43.02957153 53.76282501 -45.02964783
|
||||
v -37.12292480 61.50623322 -18.93314743
|
||||
v -30.75580597 66.39993286 8.10605431
|
||||
v -26.88832855 69.09246826 32.87157822
|
||||
v -28.48061752 70.23239136 52.14703751
|
||||
v -38.49278641 70.46823883 62.71599197
|
||||
v -53.13377380 68.93627167 62.32793045
|
||||
v -66.29364777 64.98539734 52.53622818
|
||||
v -77.45420837 59.58318329 35.83026123
|
||||
v -86.09729004 53.69718933 14.69950485
|
||||
v -91.70471191 48.29497528 -8.36663914
|
||||
v -93.75828552 44.34410095 -30.87874222
|
||||
v -91.73982239 42.81213379 -50.34735489
|
||||
v -89.87214661 43.91723251 -66.58690643
|
||||
v -92.01886749 46.76722717 -80.05120850
|
||||
v -97.12301636 50.66415787 -89.21000671
|
||||
v -104.12763977 54.91006470 -92.53303528
|
||||
v -111.97578430 58.80699158 -88.49005127
|
||||
v -119.61050415 61.65698624 -75.55078125
|
||||
v -125.97479248 62.76208496 -52.18497467
|
||||
# 36 vertices
|
||||
|
||||
g Line001
|
||||
usemtl wire_088177027
|
||||
l 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36
|
||||
@@ -166,7 +166,7 @@ class TestBlob < Minitest::Test
|
||||
assert sample_blob_memory("JavaScript/jquery-1.4.2.min.js").generated?
|
||||
|
||||
# Composer generated composer.lock file
|
||||
assert sample_blob_memory("JSON/composer.lock").generated?
|
||||
assert sample_blob_memory("JSON/filenames/composer.lock").generated?
|
||||
|
||||
# PEG.js-generated parsers
|
||||
assert sample_blob_memory("JavaScript/parser.js").generated?
|
||||
|
||||
@@ -411,6 +411,10 @@ class TestFileBlob < Minitest::Test
|
||||
assert sample_blob("public/javascripts/tiny_mce_popup.js").vendored?
|
||||
assert sample_blob("public/javascripts/tiny_mce_src.js").vendored?
|
||||
|
||||
# Ace Editor
|
||||
assert sample_blob("ace-builds/src/ace.js").vendored?
|
||||
assert sample_blob("static/project/ace-builds/src/ace.js").vendored?
|
||||
|
||||
# AngularJS
|
||||
assert sample_blob("public/javascripts/angular.js").vendored?
|
||||
assert sample_blob("public/javascripts/angular.min.js").vendored?
|
||||
|
||||
@@ -36,7 +36,7 @@ class TestGenerated < Minitest::Test
|
||||
generated_loading_data(File.join(samples_path, name))
|
||||
end
|
||||
|
||||
def test_check_generated
|
||||
def test_check_generated
|
||||
# Xcode project files
|
||||
generated_sample_without_loading_data("Binary/MainMenu.nib")
|
||||
generated_sample_without_loading_data("Dummy/foo.xcworkspacedata")
|
||||
@@ -51,6 +51,9 @@ class TestGenerated < Minitest::Test
|
||||
# Node modules
|
||||
generated_sample_without_loading_data("Dummy/node_modules/foo.js")
|
||||
|
||||
# npm shrinkwrap file
|
||||
generated_sample_without_loading_data("Dummy/npm-shrinkwrap.json")
|
||||
|
||||
# Godep saved dependencies
|
||||
generated_sample_without_loading_data("Godeps/Godeps.json")
|
||||
generated_sample_without_loading_data("Godeps/_workspace/src/github.com/kr/s3/sign.go")
|
||||
|
||||
2
vendor/grammars/AutoHotkey
vendored
2
vendor/grammars/AutoHotkey
vendored
Submodule vendor/grammars/AutoHotkey updated: 02fe2a8d3d...6ba0aedaf8
1
vendor/grammars/Elm
vendored
Submodule
1
vendor/grammars/Elm
vendored
Submodule
Submodule vendor/grammars/Elm added at 8e8af4a712
1
vendor/grammars/Elm.tmLanguage
vendored
1
vendor/grammars/Elm.tmLanguage
vendored
Submodule vendor/grammars/Elm.tmLanguage deleted from 155ce91c81
2
vendor/grammars/Handlebars
vendored
2
vendor/grammars/Handlebars
vendored
Submodule vendor/grammars/Handlebars updated: 2e9f688400...94ef9439d8
2
vendor/grammars/MagicPython
vendored
2
vendor/grammars/MagicPython
vendored
Submodule vendor/grammars/MagicPython updated: fd23525656...820a9310f6
2
vendor/grammars/Sublime-Coq
vendored
2
vendor/grammars/Sublime-Coq
vendored
Submodule vendor/grammars/Sublime-Coq updated: 0909903a9a...ea5057282e
2
vendor/grammars/SublimePapyrus
vendored
2
vendor/grammars/SublimePapyrus
vendored
Submodule vendor/grammars/SublimePapyrus updated: 66a085b1fd...51ec72ab00
2
vendor/grammars/atom-fsharp
vendored
2
vendor/grammars/atom-fsharp
vendored
Submodule vendor/grammars/atom-fsharp updated: 6470266565...4f9d5510f3
1
vendor/grammars/atom-language-clean
vendored
Submodule
1
vendor/grammars/atom-language-clean
vendored
Submodule
Submodule vendor/grammars/atom-language-clean added at a9b837801d
1
vendor/grammars/atom-language-srt
vendored
Submodule
1
vendor/grammars/atom-language-srt
vendored
Submodule
Submodule vendor/grammars/atom-language-srt added at 386b4b64ae
2
vendor/grammars/atomic-dreams
vendored
2
vendor/grammars/atomic-dreams
vendored
Submodule vendor/grammars/atomic-dreams updated: 4384f94ff3...7a4fb5a692
2
vendor/grammars/bro-sublime
vendored
2
vendor/grammars/bro-sublime
vendored
Submodule vendor/grammars/bro-sublime updated: 8219f5ee09...28125c911e
1
vendor/grammars/creole
vendored
Submodule
1
vendor/grammars/creole
vendored
Submodule
Submodule vendor/grammars/creole added at cdc8adc306
2
vendor/grammars/d.tmbundle
vendored
2
vendor/grammars/d.tmbundle
vendored
Submodule vendor/grammars/d.tmbundle updated: 9b7d4a8e44...e4beff2ce5
2
vendor/grammars/html.tmbundle
vendored
2
vendor/grammars/html.tmbundle
vendored
Submodule vendor/grammars/html.tmbundle updated: 7710c79b16...2e9e024a1b
2
vendor/grammars/language-apl
vendored
2
vendor/grammars/language-apl
vendored
Submodule vendor/grammars/language-apl updated: 37552fbbf9...3a951edcb8
2
vendor/grammars/language-babel
vendored
2
vendor/grammars/language-babel
vendored
Submodule vendor/grammars/language-babel updated: cde20a210f...265937e465
2
vendor/grammars/language-clojure
vendored
2
vendor/grammars/language-clojure
vendored
Submodule vendor/grammars/language-clojure updated: bf4ad48378...d41af28800
2
vendor/grammars/language-coffee-script
vendored
2
vendor/grammars/language-coffee-script
vendored
Submodule vendor/grammars/language-coffee-script updated: 3f79112bb2...9ebf474016
2
vendor/grammars/language-crystal
vendored
2
vendor/grammars/language-crystal
vendored
Submodule vendor/grammars/language-crystal updated: f87d68645c...ec1e4991e6
2
vendor/grammars/language-csharp
vendored
2
vendor/grammars/language-csharp
vendored
Submodule vendor/grammars/language-csharp updated: efac6d4865...b3f1130b1a
1
vendor/grammars/language-csound
vendored
Submodule
1
vendor/grammars/language-csound
vendored
Submodule
Submodule vendor/grammars/language-csound added at f5c603ac11
2
vendor/grammars/language-gfm
vendored
2
vendor/grammars/language-gfm
vendored
Submodule vendor/grammars/language-gfm updated: 0e5e65d205...5435923521
2
vendor/grammars/language-javascript
vendored
2
vendor/grammars/language-javascript
vendored
Submodule vendor/grammars/language-javascript updated: 5fb7053b45...83f9e51bc9
2
vendor/grammars/language-jsoniq
vendored
2
vendor/grammars/language-jsoniq
vendored
Submodule vendor/grammars/language-jsoniq updated: 008a24589d...7e2a77f372
2
vendor/grammars/language-less
vendored
2
vendor/grammars/language-less
vendored
Submodule vendor/grammars/language-less updated: ac726d84f2...234fd8a37b
2
vendor/grammars/language-povray
vendored
2
vendor/grammars/language-povray
vendored
Submodule vendor/grammars/language-povray updated: 35b3705991...c9e175fd41
2
vendor/grammars/language-python
vendored
2
vendor/grammars/language-python
vendored
Submodule vendor/grammars/language-python updated: e981159420...d5ae69749b
2
vendor/grammars/language-renpy
vendored
2
vendor/grammars/language-renpy
vendored
Submodule vendor/grammars/language-renpy updated: 64ffc56191...883f51f4ef
1
vendor/grammars/language-restructuredtext
vendored
Submodule
1
vendor/grammars/language-restructuredtext
vendored
Submodule
Submodule vendor/grammars/language-restructuredtext added at 7133612568
2
vendor/grammars/language-shellscript
vendored
2
vendor/grammars/language-shellscript
vendored
Submodule vendor/grammars/language-shellscript updated: 8fe135d8f4...8019ad833c
2
vendor/grammars/language-toc-wow
vendored
2
vendor/grammars/language-toc-wow
vendored
Submodule vendor/grammars/language-toc-wow updated: 222248b767...f538862fdd
1
vendor/grammars/language-turing
vendored
Submodule
1
vendor/grammars/language-turing
vendored
Submodule
Submodule vendor/grammars/language-turing added at 5f1d5f2f1a
1
vendor/grammars/language-wavefront
vendored
Submodule
1
vendor/grammars/language-wavefront
vendored
Submodule
Submodule vendor/grammars/language-wavefront added at 4bebab3f9a
2
vendor/grammars/language-yaml
vendored
2
vendor/grammars/language-yaml
vendored
Submodule vendor/grammars/language-yaml updated: 2f64544195...9f55beb635
2
vendor/grammars/latex.tmbundle
vendored
2
vendor/grammars/latex.tmbundle
vendored
Submodule vendor/grammars/latex.tmbundle updated: b94521204a...a5c14e1ce9
2
vendor/grammars/mako-tmbundle
vendored
2
vendor/grammars/mako-tmbundle
vendored
Submodule vendor/grammars/mako-tmbundle updated: da79638669...45037e4e98
1
vendor/grammars/nu.tmbundle
vendored
Submodule
1
vendor/grammars/nu.tmbundle
vendored
Submodule
Submodule vendor/grammars/nu.tmbundle added at 66e79b5e56
2
vendor/grammars/pawn-sublime-language
vendored
2
vendor/grammars/pawn-sublime-language
vendored
Submodule vendor/grammars/pawn-sublime-language updated: f49e709a23...879fae6157
2
vendor/grammars/perl6fe
vendored
2
vendor/grammars/perl6fe
vendored
Submodule vendor/grammars/perl6fe updated: f3fe47aa8d...7f646ac13a
1
vendor/grammars/restructuredtext.tmbundle
vendored
1
vendor/grammars/restructuredtext.tmbundle
vendored
Submodule vendor/grammars/restructuredtext.tmbundle deleted from 608d8bcdea
2
vendor/grammars/ruby-slim.tmbundle
vendored
2
vendor/grammars/ruby-slim.tmbundle
vendored
Submodule vendor/grammars/ruby-slim.tmbundle updated: 0baf7a453c...7452b27ea4
2
vendor/grammars/sas.tmbundle
vendored
2
vendor/grammars/sas.tmbundle
vendored
Submodule vendor/grammars/sas.tmbundle updated: ba5c74624c...012368ab93
2
vendor/grammars/sublime-glsl
vendored
2
vendor/grammars/sublime-glsl
vendored
Submodule vendor/grammars/sublime-glsl updated: 0443b921df...e29059b0d3
2
vendor/grammars/sublime-pony
vendored
2
vendor/grammars/sublime-pony
vendored
Submodule vendor/grammars/sublime-pony updated: b5eb8f8e97...02f37b174e
2
vendor/grammars/sublime-rust
vendored
2
vendor/grammars/sublime-rust
vendored
Submodule vendor/grammars/sublime-rust updated: f75f2b1026...167018cc0f
2
vendor/grammars/sublime-typescript
vendored
2
vendor/grammars/sublime-typescript
vendored
Submodule vendor/grammars/sublime-typescript updated: 7709dd317f...0d538fc748
2
vendor/grammars/sublimeassembly
vendored
2
vendor/grammars/sublimeassembly
vendored
Submodule vendor/grammars/sublimeassembly updated: cb9c99a4a9...edb58c8246
2
vendor/grammars/swift.tmbundle
vendored
2
vendor/grammars/swift.tmbundle
vendored
Submodule vendor/grammars/swift.tmbundle updated: 32141e91ee...662fd22bf8
2
vendor/grammars/vue-syntax-highlight
vendored
2
vendor/grammars/vue-syntax-highlight
vendored
Submodule vendor/grammars/vue-syntax-highlight updated: b4c91d1b32...a29a875bf3
@@ -1,6 +1,6 @@
|
||||
---
|
||||
type: grammar
|
||||
name: Elm.tmLanguage
|
||||
name: Elm
|
||||
license: mit
|
||||
---
|
||||
The MIT License (MIT)
|
||||
25
vendor/licenses/grammar/atom-language-clean.txt
vendored
Normal file
25
vendor/licenses/grammar/atom-language-clean.txt
vendored
Normal file
@@ -0,0 +1,25 @@
|
||||
---
|
||||
type: grammar
|
||||
name: atom-language-clean
|
||||
license: mit
|
||||
---
|
||||
Copyright (c) 2015 <Your name here>
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining
|
||||
a copy of this software and associated documentation files (the
|
||||
"Software"), to deal in the Software without restriction, including
|
||||
without limitation the rights to use, copy, modify, merge, publish,
|
||||
distribute, sublicense, and/or sell copies of the Software, and to
|
||||
permit persons to whom the Software is furnished to do so, subject to
|
||||
the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be
|
||||
included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
||||
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
||||
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
||||
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
25
vendor/licenses/grammar/atom-language-srt.txt
vendored
Normal file
25
vendor/licenses/grammar/atom-language-srt.txt
vendored
Normal file
@@ -0,0 +1,25 @@
|
||||
---
|
||||
type: grammar
|
||||
name: atom-language-srt
|
||||
license: mit
|
||||
---
|
||||
Copyright (c) 2016 Pieter Goetschalckx
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining
|
||||
a copy of this software and associated documentation files (the
|
||||
"Software"), to deal in the Software without restriction, including
|
||||
without limitation the rights to use, copy, modify, merge, publish,
|
||||
distribute, sublicense, and/or sell copies of the Software, and to
|
||||
permit persons to whom the Software is furnished to do so, subject to
|
||||
the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be
|
||||
included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
||||
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
||||
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
||||
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
19
vendor/licenses/grammar/creole.txt
vendored
Normal file
19
vendor/licenses/grammar/creole.txt
vendored
Normal file
@@ -0,0 +1,19 @@
|
||||
---
|
||||
type: grammar
|
||||
name: creole
|
||||
license: mit
|
||||
---
|
||||
The MIT License (MIT)
|
||||
Copyright (c) 2012 Siddley
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files
|
||||
(the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge,
|
||||
publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so,
|
||||
subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE
|
||||
FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
12
vendor/licenses/grammar/language-csound.txt
vendored
Normal file
12
vendor/licenses/grammar/language-csound.txt
vendored
Normal file
@@ -0,0 +1,12 @@
|
||||
---
|
||||
type: grammar
|
||||
name: language-csound
|
||||
license: mit
|
||||
---
|
||||
Copyright © 2015–2016 Nathan Whetsell
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
26
vendor/licenses/grammar/language-restructuredtext.txt
vendored
Normal file
26
vendor/licenses/grammar/language-restructuredtext.txt
vendored
Normal file
@@ -0,0 +1,26 @@
|
||||
---
|
||||
type: grammar
|
||||
name: language-restructuredtext
|
||||
license: mit
|
||||
---
|
||||
MIT License
|
||||
|
||||
Copyright (c) 2014-2016 Cory Benfield
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
18
vendor/licenses/grammar/language-turing.txt
vendored
Normal file
18
vendor/licenses/grammar/language-turing.txt
vendored
Normal file
@@ -0,0 +1,18 @@
|
||||
---
|
||||
type: grammar
|
||||
name: language-turing
|
||||
license: isc
|
||||
---
|
||||
Copyright (c) 2016, John Gardner
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
18
vendor/licenses/grammar/language-wavefront.txt
vendored
Normal file
18
vendor/licenses/grammar/language-wavefront.txt
vendored
Normal file
@@ -0,0 +1,18 @@
|
||||
---
|
||||
type: grammar
|
||||
name: language-wavefront
|
||||
license: isc
|
||||
---
|
||||
Copyright (c) 2016, John Gardner
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user