Skip to content
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
10 changes: 5 additions & 5 deletions .devcontainer/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# XcodeBuildServer Dev Container
# sourcekit-bsp Dev Container

This Dev Container configuration allows you to develop XcodeBuildServer without needing an Xcode environment, while running code quality tools like SwiftLint and SwiftFormat.
This Dev Container configuration allows you to develop sourcekit-bsp without needing an Xcode environment, while running code quality tools like SwiftLint and SwiftFormat.

## Features

Expand Down Expand Up @@ -31,7 +31,7 @@ swift build
swift test

# Run specific target
swift run XcodeBuildServerCLI
swift run sourcekit-bsp

# Clean build
swift package clean
Expand Down Expand Up @@ -60,7 +60,7 @@ bsp-build # swift build + success message
bsp-test # swift test --parallel

# Debug
bsp-debug # BSP_DEBUG=1 swift run XcodeBuildServerCLI
bsp-debug # BSP_DEBUG=1 swift run sourcekit-bsp

# Code quality
lint # swiftlint && swiftformat --lint .
Expand All @@ -76,7 +76,7 @@ format # swiftformat . && swiftlint --fix

```bash
# Start debug mode
BSP_DEBUG=1 swift run XcodeBuildServerCLI
BSP_DEBUG=1 swift run sourcekit-bsp

# Or use alias
bsp-debug
Expand Down
2 changes: 1 addition & 1 deletion .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "XcodeBuildServer Swift Development",
"name": "sourcekit-bsp Swift Development",
"image": "swift:6.1-noble",
"features": {
"ghcr.io/devcontainers/features/common-utils:2": {
Expand Down
8 changes: 4 additions & 4 deletions .devcontainer/setup.sh
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
#!/bin/bash

# XcodeBuildServer Dev Container Setup Script
# sourcekit-bsp Dev Container Setup Script

SWIFTLINT_VERSION="0.60.0"
SWIFTFORMAT_VERSION="0.57.2"

set -e

echo "🚀 Setting up XcodeBuildServer development environment..."
echo "🚀 Setting up sourcekit-bsp development environment..."

# Update package lists
echo "📦 Updating package lists..."
Expand Down Expand Up @@ -84,7 +84,7 @@ swift package resolve
echo "🔧 Setting up aliases..."
cat >> ~/.zshrc << 'EOF'

# XcodeBuildServer Development Aliases
# sourcekit-bsp Development Aliases
alias swiftbuild='swift build'
alias swifttest='swift test'
alias swiftrun='swift run'
Expand All @@ -97,7 +97,7 @@ alias lint='swiftlint && swiftformat --lint .'
alias format='swiftformat . && swiftlint --fix'

# BSP Development
alias bsp-debug='BSP_DEBUG=1 swift run XcodeBuildServerCLI'
alias bsp-debug='BSP_DEBUG=1 swift run sourcekit-bsp'
alias bsp-build='swift build && echo "✅ Build complete!"'
alias bsp-test='swift test --parallel'

Expand Down
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ body:
id: version
attributes:
label: Version
description: What version of XcodeBuildServer are you running?
description: What version of sourcekit-bsp are you running?
placeholder: ex. v1.0.0
validations:
required: true
Expand Down
4 changes: 2 additions & 2 deletions .github/TROUBLESHOOTING.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# GitHub Actions Troubleshooting Guide

This guide helps you resolve common issues with the GitHub Actions workflows in XcodeBuildServer.
This guide helps you resolve common issues with the GitHub Actions workflows in sourcekit-bsp.

## Common Issues and Solutions

Expand Down Expand Up @@ -98,7 +98,7 @@ This guide helps you resolve common issues with the GitHub Actions workflows in
uses: actions/upload-artifact@v4
with:
name: xcode-build-server
path: .build/release/XcodeBuildServerCLI
path: .build/release/sourcekit-bsp
```

### 6. Cache Issues
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# GitHub Actions Workflows

This directory contains all the GitHub Actions workflows for XcodeBuildServer. Each workflow serves a specific purpose in our CI/CD pipeline.
This directory contains all the GitHub Actions workflows for sourcekit-bsp. Each workflow serves a specific purpose in our CI/CD pipeline.

## Workflows Overview

Expand Down Expand Up @@ -94,10 +94,10 @@ This directory contains all the GitHub Actions workflows for XcodeBuildServer. E
The following badges are available for the README:

```markdown
[![CI](https://github.com/wang.lun/XcodeBuildServer/workflows/CI/badge.svg)](https://github.com/wang.lun/XcodeBuildServer/actions/workflows/ci.yml)
[![Release](https://github.com/wang.lun/XcodeBuildServer/workflows/Release/badge.svg)](https://github.com/wang.lun/XcodeBuildServer/actions/workflows/release.yml)
[![Code Quality](https://github.com/wang.lun/XcodeBuildServer/workflows/Code%20Quality/badge.svg)](https://github.com/wang.lun/XcodeBuildServer/actions/workflows/code-quality.yml)
[![Security](https://github.com/wang.lun/XcodeBuildServer/workflows/Security/badge.svg)](https://github.com/wang.lun/XcodeBuildServer/actions/workflows/security.yml)
[![CI](https://github.com/wang.lun/sourcekit-bsp/workflows/CI/badge.svg)](https://github.com/wang.lun/sourcekit-bsp/actions/workflows/ci.yml)
[![Release](https://github.com/wang.lun/sourcekit-bsp/workflows/Release/badge.svg)](https://github.com/wang.lun/sourcekit-bsp/actions/workflows/release.yml)
[![Code Quality](https://github.com/wang.lun/sourcekit-bsp/workflows/Code%20Quality/badge.svg)](https://github.com/wang.lun/sourcekit-bsp/actions/workflows/code-quality.yml)
[![Security](https://github.com/wang.lun/sourcekit-bsp/workflows/Security/badge.svg)](https://github.com/wang.lun/sourcekit-bsp/actions/workflows/security.yml)
```

## Workflow Dependencies
Expand Down
26 changes: 13 additions & 13 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,28 +40,28 @@ jobs:
- name: Create Release Archive
run: |
mkdir -p release
cp .build/apple/Products/Release/XcodeBuildServerCLI release/XcodeBuildServerCLI
cp .build/apple/Products/Release/sourcekit-bsp release/sourcekit-bsp
cp .build/apple/Products/Release/XcodeProjectCLI release/XcodeProjectCLI
chmod +x release/XcodeBuildServerCLI
chmod +x release/sourcekit-bsp
chmod +x release/XcodeProjectCLI

# Create tar.gz
tar -czf xcode-build-server-macos-universal.tar.gz -C release XcodeBuildServerCLI XcodeProjectCLI
tar -czf sourcekit-bsp-macos-universal.tar.gz -C release sourcekit-bsp XcodeProjectCLI

# Create zip
cd release && zip ../xcode-build-server-macos-universal.zip XcodeBuildServerCLI XcodeProjectCLI && cd ..
cd release && zip ../sourcekit-bsp-macos-universal.zip sourcekit-bsp XcodeProjectCLI && cd ..

- name: Generate Checksums
run: |
shasum -a 256 xcode-build-server-macos-universal.tar.gz > checksums.txt
shasum -a 256 xcode-build-server-macos-universal.zip >> checksums.txt
shasum -a 256 sourcekit-bsp-macos-universal.tar.gz > checksums.txt
shasum -a 256 sourcekit-bsp-macos-universal.zip >> checksums.txt

- name: Create Release
uses: softprops/action-gh-release@v1
with:
files: |
xcode-build-server-macos-universal.tar.gz
xcode-build-server-macos-universal.zip
sourcekit-bsp-macos-universal.tar.gz
sourcekit-bsp-macos-universal.zip
checksums.txt
generate_release_notes: true
prerelease: ${{ contains(github.ref_name, 'alpha') || contains(github.ref_name, 'beta') || contains(github.ref_name, 'rc') }}
Expand All @@ -73,18 +73,18 @@ jobs:
#### Homebrew (Recommended)
```bash
# Coming soon
brew install XcodeBuildServerCLI
brew install sourcekit-bsp
```

#### Manual Installation
1. Download the appropriate archive for your platform
2. Extract the binary: `tar -xzf xcode-build-server-macos-universal.tar.gz`
3. Move to PATH: `mv XcodeBuildServerCLI /usr/local/bin/`
4. Make executable: `chmod +x /usr/local/bin/XcodeBuildServerCLI`
2. Extract the binary: `tar -xzf sourcekit-bsp-macos-universal.tar.gz`
3. Move to PATH: `mv sourcekit-bsp /usr/local/bin/`
4. Make executable: `chmod +x /usr/local/bin/sourcekit-bsp`

### Usage
```bash
XcodeBuildServerCLI --help
sourcekit-bsp --help
```

### Checksums
Expand Down
26 changes: 13 additions & 13 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,40 +4,40 @@
{
"type": "lldb",
"request": "launch",
"name": "Build Debug XcodeBuildServerCLI",
"program": "${workspaceFolder}/.build/debug/XcodeBuildServerCLI",
"preLaunchTask": "swift: Build Debug XcodeBuildServerCLI"
"name": "Build Debug sourcekit-bsp",
"program": "${workspaceFolder}/.build/debug/sourcekit-bsp",
"preLaunchTask": "swift: Build Debug sourcekit-bsp"
},
{
"type": "lldb",
"request": "attach",
"waitFor": true,
"name": "Wait and attach XcodeBuildServerCLI",
"program": "${workspaceFolder}/.build/debug/XcodeBuildServerCLI"
"name": "Wait and attach sourcekit-bsp",
"program": "${workspaceFolder}/.build/debug/sourcekit-bsp"
},
{
"type": "swift",
"request": "launch",
"args": [],
"cwd": "${workspaceFolder}",
"name": "Release XcodeBuildServerCLI",
"program": "${workspaceFolder}/.build/release/XcodeBuildServerCLI",
"preLaunchTask": "swift: Build Release XcodeBuildServerCLI"
"name": "Release sourcekit-bsp",
"program": "${workspaceFolder}/.build/release/sourcekit-bsp",
"preLaunchTask": "swift: Build Release sourcekit-bsp"
},
{
"type": "swift",
"request": "launch",
"args": [],
"cwd": "${workspaceFolder}",
"name": "Debug XcodeBuildServerCLI",
"program": "${workspaceFolder}/.build/debug/XcodeBuildServerCLI",
"preLaunchTask": "swift: Build Debug XcodeBuildServerCLI"
"name": "Debug sourcekit-bsp",
"program": "${workspaceFolder}/.build/debug/sourcekit-bsp",
"preLaunchTask": "swift: Build Debug sourcekit-bsp"
},
{
"type": "lldb",
"request": "attach",
"name": "Attach to XcodeBuildServerCLI",
"program": "${workspaceFolder}/.build/debug/XcodeBuildServerCLI",
"name": "Attach to sourcekit-bsp",
"program": "${workspaceFolder}/.build/debug/sourcekit-bsp",
"waitFor": true,
"preLaunchTask": ""
},
Expand Down
2 changes: 1 addition & 1 deletion .vscode/tasks.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"version": "2.0.0",
"tasks": [
{
"label": "swift: Build Debug XcodeBuildServerCLI",
"label": "swift: Build Debug sourcekit-bsp",
"type": "shell",
"command": "swift build -c debug",
"group": {
Expand Down
10 changes: 5 additions & 5 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Contributing to XcodeBuildServer
# Contributing to sourcekit-bsp

Thank you for your interest in contributing to XcodeBuildServer! This document provides guidelines and information for contributors.
Thank you for your interest in contributing to sourcekit-bsp! This document provides guidelines and information for contributors.

## Code of Conduct

Expand Down Expand Up @@ -38,8 +38,8 @@ This project adheres to a [Code of Conduct](CODE_OF_CONDUCT.md). By participatin

1. **Fork and clone** the repository:
```bash
git clone https://github.com/yourusername/XcodeBuildServer.git
cd XcodeBuildServer
git clone https://github.com/yourusername/sourcekit-bsp.git
cd sourcekit-bsp
```

2. **Install dependencies**:
Expand Down Expand Up @@ -257,4 +257,4 @@ Contributors are recognized in:
- Release notes
- GitHub contributors page

Thank you for contributing to XcodeBuildServer!
Thank you for contributing to sourcekit-bsp!
10 changes: 5 additions & 5 deletions Docs/BSP-Implementation-Guide.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# BSP服务器实现指南 - XcodeBuildServer
# BSP服务器实现指南 - sourcekit-bsp

基于 [SourceKit-LSP官方BSP服务器实现指南](https://github.com/swiftlang/sourcekit-lsp/blob/56a91e90212400f20bb9d3f2e563ea8cda7634f6/Contributor%20Documentation/Implementing%20a%20BSP%20server.md) 的完整实现文档。

Expand All @@ -15,7 +15,7 @@ SourceKit-LSP可以通过[Build Server Protocol (BSP)](https://build-server-prot
- **必需响应字段**:
```json
{
"displayName": "XcodeBuildServer",
"displayName": "sourcekit-bsp",
"version": "1.0.0",
"bspVersion": "2.2.0",
"capabilities": {
Expand Down Expand Up @@ -248,7 +248,7 @@ public struct Result: Codable, Hashable, Sendable {
- **用途**:处理SourceKit-LSP发送的用户消息
- **实现状态**:✅ 已实现

## XcodeBuildServer特有实现
## sourcekit-bsp特有实现

### 项目发现和解析
```swift
Expand Down Expand Up @@ -286,11 +286,11 @@ let toolchainURI = URI(string: "file://\(toolchainPath)")

```json
{
"name": "XcodeBuildServer",
"name": "sourcekit-bsp",
"version": "1.0.0",
"bspVersion": "2.2.0",
"languages": ["swift", "objective-c", "objective-cpp", "c", "cpp"],
"argv": ["/path/to/XcodeBuildServerCLI"],
"argv": ["/path/to/sourcekit-bsp"],
"rootUri": "file:///path/to/project"
}
```
Expand Down
4 changes: 2 additions & 2 deletions Docs/XcodeProjects-to-BuildTargets.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

## 概览

本文档描述了XcodeBuildServer如何扫描和解析工作目录,获取BSP目标和构建设置索引(编译参数)以供LSP使用。
本文档描述了sourcekit-bsp如何扫描和解析工作目录,获取BSP目标和构建设置索引(编译参数)以供LSP使用。

## 目录结构支持的情况

Expand All @@ -26,7 +26,7 @@
## 配置文件

### 配置路径
`.XcodeBuildServer/project.json`
`.sourcekit-bsp/project.json`

### 配置格式
```json
Expand Down
8 changes: 4 additions & 4 deletions Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ let multiPlatformTargets: [Target] = [
]
),
.executableTarget(
name: "XcodeBuildServerCLI",
name: "sourcekit-bsp",
dependencies: [
"BSPServer",
"Logger",
Expand Down Expand Up @@ -95,8 +95,8 @@ let multiPlatformProducts: [Product] = [
),
.library(name: "BSPServer", targets: ["BSPServer"]),
.executable(
name: "XcodeBuildServerCLI",
targets: ["XcodeBuildServerCLI"]
name: "sourcekit-bsp",
targets: ["sourcekit-bsp"]
),
]

Expand Down Expand Up @@ -217,7 +217,7 @@ let dependencies: [PackageDescription.Package.Dependency] = [
]

let package = Package(
name: "XcodeBuildServer",
name: "sourcekit-bsp",
platforms: [.macOS(.v13)],
products: products,
dependencies: dependencies,
Expand Down
Loading