Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/spotify/scio-idea-plugin
Scio IDEA plugin
https://github.com/spotify/scio-idea-plugin
idea intellij scala scala-macros
Last synced: about 2 hours ago
JSON representation
Scio IDEA plugin
- Host: GitHub
- URL: https://github.com/spotify/scio-idea-plugin
- Owner: spotify
- License: apache-2.0
- Created: 2016-09-01T16:33:05.000Z (about 8 years ago)
- Default Branch: main
- Last Pushed: 2024-11-06T09:17:14.000Z (1 day ago)
- Last Synced: 2024-11-06T10:34:43.793Z (1 day ago)
- Topics: idea, intellij, scala, scala-macros
- Language: Scala
- Homepage: https://github.com/spotify/scio
- Size: 282 KB
- Stars: 30
- Watchers: 24
- Forks: 18
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Scio plugin for IntelliJ IDEA
[![Continuous Integration](https://github.com/spotify/scio-idea-plugin/actions/workflows/ci.yml/badge.svg)](https://github.com/spotify/scio-idea-plugin/actions/workflows/ci.yml)
[![GitHub license](https://img.shields.io/github/license/spotify/scio-idea-plugin.svg)](./LICENSE)Scio plugin for IDEA, enables BigQuery macro support in IDEA.
# Raison d'être
Due to issue [SCL-8834](https://youtrack.jetbrains.com/oauth?state=%2Fissue%2FSCL-8834) case classes generated by
`@BigQueryType.fromTable` or `@BigQueryType.fromQuery` etc, are not recognized in IntelliJ IDEA. This plugin
exists to mitigate this issue. Should SCL-8834 get fixed, this plugin should be obsolete.# Install
Inside IntelliJ, `Preferences` -> `Plugins` -> `Browse repositories ...` and search `Scio`.
## Build locally:
```bash
sbt packageArtifactZip
```Zipped and ready to install plugin is inside `target`.
To install, inside IntelliJ: `Settings` -> `Plugins` -> `Gear Icon` -> `Install plugin from disk`# Usage
Install following instructions above. Plugin should work out of the box.
## BigQuery location
If you get the location (EU/US) error - you need to add location setting to scala compiler in your IntelliJ.
The easiest way is to click on the weird looking "clock" in the bottom-right corner - it's actually a shortcut to scala compiler.
If it's already running - stop it, then press `Configure...` and in `JVM parameters` add `-Dbigquery.staging_dataset.location=EU`.You should upgrade Scio to version >= `0.2.1` - starting from that version `bigquery.staging_dataset.location` is obsolete.
## User interaction
If Scio plugin can't find scala files, it will log an error via IntelliJ Event Log, which you should see via red bubble
in the lower-right corner. The message should inform you that, you need to recompile the project. Follow the instructions.If you rebuild the project, plugin should react in a matter of seconds - if completion is still not there,
poke the code around, wait a minute or two. At this point plugin simply reacts to IntelliJ events,
which sporadically take a while to propagate.# Logging
This plugin uses IDEA diagnostic logger, you can find log files
under standard IntelliJ directory ([doc](https://intellij-support.jetbrains.com/hc/en-us/articles/206544519-Directories-used-by-the-IDE-to-store-settings-caches-plugins-and-logs)). For example for macOS: `~/Library/Logs//idea.log`.If there is error level message logged, it will show up in IntelliJ Event Log.
# License
Copyright 2019 Spotify AB.
Licensed under the Apache License, Version 2.0: http://www.apache.org/licenses/LICENSE-2.0