Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add more license #3994

Merged
merged 2 commits into from
Aug 16, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
164 changes: 108 additions & 56 deletions libs/remix-ui/editor/src/lib/providers/quickfixes.ts
Original file line number Diff line number Diff line change
@@ -1,58 +1,110 @@
export default {
"Warning: SPDX license identifier not provided in source file. Before publishing, consider adding a comment containing \"SPDX-License-Identifier: <SPDX-License>\" to each source file. Use \"SPDX-License-Identifier: UNLICENSED\" for non-open-source code. Please see https://spdx.org for more information.": [{
"id": 1.1,
"nodeType": "SourceUnit",
"title": "Add open-source license",
"message": "// SPDX-License-Identifier: GPL-3.0"
},{
"id": 1.2,
"nodeType": "SourceUnit",
"title": "Add non-open-source license",
"message": "// SPDX-License-Identifier: UNLICENSED"
}],
"Warning: Source file does not specify required compiler version! Consider adding" : [{
"id": 2,
"title": "Add Solidity pragma",
"message": "pragma solidity ^0.*.*;",
"nodeType": "PragmaDirective",
"range": {
startLineNumber: 2,
endLineNumber: 2,
startColumn: 1,
endColumn: 1
'Warning: SPDX license identifier not provided in source file. Before publishing, consider adding a comment containing "SPDX-License-Identifier: <SPDX-License>" to each source file. Use "SPDX-License-Identifier: UNLICENSED" for non-open-source code. Please see https://spdx.org for more information.':
[
{
id: 1.1,
nodeType: 'SourceUnit',
title: 'Add non-open-source license',
message: '// SPDX-License-Identifier: UNLICENSED'
},
{
id: 1.2,
nodeType: 'SourceUnit',
title: 'Add Apache-1.1 license',
message: '// SPDX-License-Identifier: Apache-1.1'
},
{
id: 1.3,
nodeType: 'SourceUnit',
title: 'Add Apache-2.0 license',
message: '// SPDX-License-Identifier: Apache-2.0'
},
{
id: 1.4,
nodeType: 'SourceUnit',
title: 'Add MIT license',
message: '// SPDX-License-Identifier: MIT'
},
{
id: 1.5,
nodeType: 'SourceUnit',
title: 'Add EPL-1.0 (Eclipse) license',
message: '// SPDX-License-Identifier: EPL-1.0'
},
{
id: 1.6,
nodeType: 'SourceUnit',
title: 'Add EPL-2.0 (Eclipse) license',
message: '// SPDX-License-Identifier: EPL-2.0'
},
{
id: 1.7,
nodeType: 'SourceUnit',
title: 'Add GPL-3.0-only license',
message: '// SPDX-License-Identifier: GPL-3.0-only'
},
{
id: 1.8,
nodeType: 'SourceUnit',
title: 'Add GPL-3.0-or-later license',
message: '// SPDX-License-Identifier: GPL-3.0-or-later'
}
],
'Warning: Source file does not specify required compiler version! Consider adding':
[
{
id: 2,
title: 'Add Solidity pragma',
message: 'pragma solidity ^0.*.*;',
nodeType: 'PragmaDirective',
range: {
startLineNumber: 2,
endLineNumber: 2,
startColumn: 1,
endColumn: 1
}
}
],
'SyntaxError: No visibility specified. Did you intend to add "public"': [
{
id: 3.1,
title: "Add visibility 'public'",
message: 'public ',
nodeType: 'FunctionDefinition'
},
{
id: 3.2,
title: "Add visibility 'private'",
message: 'private ',
nodeType: 'FunctionDefinition'
},
{
id: 3.3,
title: "Add visibility 'internal'",
message: 'internal ',
nodeType: 'FunctionDefinition'
},
{
id: 3.4,
title: "Add visibility 'external'",
message: 'external ',
nodeType: 'FunctionDefinition'
}
}],
"SyntaxError: No visibility specified. Did you intend to add \"public\"": [{
"id": 3.1,
"title": "Add visibility 'public'",
"message": "public ",
"nodeType": "FunctionDefinition"
},{
"id": 3.2,
"title": "Add visibility 'private'",
"message": "private ",
"nodeType": "FunctionDefinition"
},{
"id": 3.3,
"title": "Add visibility 'internal'",
"message": "internal ",
"nodeType": "FunctionDefinition"
},{
"id": 3.4,
"title": "Add visibility 'external'",
"message": "external ",
"nodeType": "FunctionDefinition"
}],
"Warning: Function state mutability can be restricted to view": [{
"id": 4,
"title": "Add mutability 'view'",
"message": "view ",
"nodeType": "FunctionDefinition"
}],
"Warning: Function state mutability can be restricted to pure": [{
"id": 5,
"title": "Add mutability 'pure'",
"message": "pure ",
"nodeType": "FunctionDefinition"
}]
}
],
'Warning: Function state mutability can be restricted to view': [
{
id: 4,
title: "Add mutability 'view'",
message: 'view ',
nodeType: 'FunctionDefinition'
}
],
'Warning: Function state mutability can be restricted to pure': [
{
id: 5,
title: "Add mutability 'pure'",
message: 'pure ',
nodeType: 'FunctionDefinition'
}
]
}
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ export const TreeViewItem = (props: TreeViewItemProps) => {
) : icon ? (
<div className={`pr-3 pl-1 ${icon} caret caret_tv`}></div>
) : null}
<span className="w-100 pb-1 pl-1">{label}</span>
<span className="w-100 pl-1">{label}</span>
</div>
{isExpanded ? children : null}
</li>
Expand Down
Loading