Orient the master cylinder horizontally and at the highest point with the brake line and caliper hanging straight down beneath it. This is easy if the line is externally routed. If you have internally routed lines then you can hang the bike to get as close to this orientation as possible. Open the reach adjust and free stroke screws to allow air out more readily.
Use the funnel filled with fluid at the master cylinder and rapidly cycle the lever. You will see bubbles in the funnel if there is air in the system when you cycle the lever. You can tap the caliper and line along its length to help dislodge any air. Use a strap to hold the lever pulled and leave the bike in this orientation for a few hours or over night. This should get all of the air out up to the reservoir. If air is the problem this should address it. If you get a firm lever after this process then close everything up and go for a mild test ride to evaluate if the performance is safe. If air enters the system rapidly after doing this then there is a leak somewhere. Look for fluid coming out somewhere as a fist step.
If this does not result in a good lever then you can try pushing some fluid with a syringe from the caliper up to the funnel.
Use the funnel filled with fluid at the master cylinder and rapidly cycle the lever. You will see bubbles in the funnel if there is air in the system when you cycle the lever. You can tap the caliper and line along its length to help dislodge any air. Use a strap to hold the lever pulled and leave the bike in this orientation for a few hours or over night. This should get all of the air out up to the reservoir. If air is the problem this should address it. If you get a firm lever after this process then close everything up and go for a mild test ride to evaluate if the performance is safe. If air enters the system rapidly after doing this then there is a leak somewhere. Look for fluid coming out somewhere as a fist step.
If this does not result in a good lever then you can try pushing some fluid with a syringe from the caliper up to the funnel.