Skip to content
This repository was archived by the owner on Aug 7, 2023. It is now read-only.

Commit 5c3f8a5

Browse files
authored
Merge pull request #68 from AtomLinter/arcanemagus/julia-1.1
Move to Julia 1.1 support
2 parents 6ae89e1 + 8e5af45 commit 5c3f8a5

File tree

3 files changed

+25
-18
lines changed

3 files changed

+25
-18
lines changed

.circleci/config.yml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ defaults: &defaults
1212
name: Install Julia v0.6.4
1313
command: |
1414
curl -o julia.tar.gz --location --silent --show-error \
15-
https://julialang-s3.julialang.org/bin/linux/x64/0.6/julia-0.6.4-linux-x86_64.tar.gz && \
15+
https://julialang-s3.julialang.org/bin/linux/x64/1.1/julia-1.1.0-linux-x86_64.tar.gz && \
1616
mkdir julia && \
1717
tar --extract --gzip --strip 1 --directory=julia --file=julia.tar.gz && \
1818
echo 'export PATH="/tmp/project/julia/bin:$PATH"' >> $BASH_ENV
@@ -22,10 +22,13 @@ defaults: &defaults
2222
- run:
2323
name: Install Lint.jl
2424
# Note the "using Lint" is to pre-compile the cache
25-
command: julia -E 'Pkg.add("Lint"); using Lint;'
25+
# Also, we are using the `master` branch directly since a working
26+
# version isn't currently released.
27+
command: |
28+
julia -E 'using Pkg; Pkg.add(PackageSpec(url="https://github.com/tonyhffong/Lint.jl", rev="master")); using Lint;'
2629
- run:
2730
name: Lint.jl version
28-
command: julia -E 'Pkg.installed("Lint")'
31+
command: julia -E 'using Pkg; Pkg.status("Lint");'
2932
- run:
3033
name: Create VFB for Atom to run in
3134
command: /usr/local/bin/xvfb_start

lib/julia-server.jl

Lines changed: 18 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,34 @@
1-
using Lint
1+
using Pkg;
2+
3+
LintPkg = PackageSpec(url="https://github.com/tonyhffong/Lint.jl", rev="master");
24

35
named_pipe = ARGS[1]
46

5-
if Pkg.installed("Lint") == nothing
6-
print(STDERR, "linter-julia-installing-lint")
7+
if get(Pkg.installed(), "Lint", nothing) == nothing == nothing
8+
print(Base.stderr, "linter-julia-installing-lint");
79
try
8-
Pkg.add("Lint")
10+
Pkg.add(LintPkg);
911
catch
10-
print(STDERR, "linter-julia-msg-install")
11-
rethrow()
12+
print(Base.stderr, "linter-julia-msg-install");
13+
rethrow();
1214
end
1315
else
14-
if Pkg.installed("Lint") < v"0.3.0"
15-
print(STDERR, "linter-julia-updating-lint")
16+
if get(Pkg.installed(), "Lint", nothing) < v"0.3.0"
17+
print(Base.stderr, "linter-julia-updating-lint");
1618
try
17-
Pkg.update("Lint")
19+
# NOTE: This doesn't appear to be working?
20+
Pkg.update(LintPkg);
1821
catch
19-
print(STDERR, "linter-julia-msg-update")
20-
rethrow()
22+
print(Base.stderr, "linter-julia-msg-update");
23+
rethrow();
2124
end
2225
else # start the server
2326
try
24-
lintserver(named_pipe,"standard-linter-v2")
27+
using Lint;
28+
lintserver(named_pipe,"standard-linter-v2");
2529
catch
26-
print(STDERR, "linter-julia-msg-load")
27-
rethrow()
30+
print(Base.stderr, "linter-julia-msg-load");
31+
rethrow();
2832
end
2933
end
3034
end

spec/linter-julia-spec.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ describe('The Julia Lint.jl provider for Linter', () => {
3030
expect(messages[0].excerpt).toBe(excerpt);
3131
expect(messages[0].location.file).toBe(badFile);
3232
// NOTE: This is invalid! Bug in Lint.jl
33-
expect(messages[0].location.position).toEqual([[1, 0], [1, 80]]);
33+
expect(messages[0].location.position).toEqual([[23, 0], [23, 80]]);
3434
});
3535

3636
it('finds nothing wrong with a valid file', async () => {

0 commit comments

Comments
 (0)